How to Type a Heart Symbol on Linux

To type a heart symbol on Linux or Ubuntu, press Ctrl + Shift + U, type 2665 and press Enter to get ♥ (2661 gives ♡). With a Compose key enabled, press Compose, then <, then 3. For emoji hearts like ❤️, use the GTK emoji chooser (Ctrl + .) or the Characters app.

Updated

Hearts you can type — or just copy

8 hearts

Tap to copy · long-press or right-click for more

On this page (8)
  1. Heart symbol on Linux: quick answer
  2. Method 1: Ctrl + Shift + U (GTK and IBus)
  3. Method 2: The Compose key
  4. Method 3: Characters app or KCharSelect
  5. Method 4: Emoji pickers
  6. Hearts in LibreOffice
  7. Hearts in the terminal and code editors
  8. Troubleshooting

Heart symbol on Linux: quick answer

Linux gives you several ways to type a heart symbol, and the best one depends on your desktop. On Ubuntu, Fedora Workstation and other GNOME-based systems, Ctrl + Shift + U is built in and works right away.

Method Steps Gives
Unicode input Ctrl + Shift + U → 2665 → Enter ♥ (any heart by code)
Compose key Compose < 3 ♥
GTK emoji chooser Ctrl + . in a GTK text field → search “heart” ❤️ 🖤 💕 and other emoji
Characters app Open Characters → search “heart” → copy ♥ ♡ ❤ ❦ and every heart

Method 1: Ctrl + Shift + U (GTK and IBus)

  1. Click in a text field.
  2. Press Ctrl + Shift + U. An underlined u appears.
  3. Type the hex code.
  4. Press Enter or Space.
Code Heart
2665 ♥
2661 ♡
2764 ❤
2763 ❣
2765 ❥
2766 ❦
2767 ❧

This works in GTK apps such as Firefox and GNOME Text Editor, and in any app where IBus is active. Chromebooks use the same shortcut.

Method 2: The Compose key

The Compose key lets you type special characters with short, memorable sequences. For a heart, the sequence is Compose, <, 3, a nod to the classic <3.

Turn it on first. The setting lives in different places:

  • Newer GNOME: Settings → Keyboard → Compose Key.
  • Older GNOME: GNOME Tweaks → Keyboard → Compose Key.
  • KDE Plasma: System Settings → Keyboard → advanced options, under the Compose key position.

Pick a key you rarely use, such as Right Alt or Menu. Then press it, release it, and type < followed by 3. The exact menu names vary between versions and distributions.

Method 3: Characters app or KCharSelect

  1. Open Characters (GNOME) or KCharSelect (KDE).
  2. Search for heart.
  3. Click a heart and copy it.
  4. Paste with Ctrl + V.

These apps show every heart your fonts support, including rare ones like ❦ and ☙, and they search by Unicode name. Try “floral” or “suit.”

Method 4: Emoji pickers

  • GTK apps: press Ctrl + . (or right-click and choose Insert Emoji) to open the emoji chooser, then search “heart.”
  • KDE Plasma: recent versions include an Emoji Selector app you can launch from the menu, often bound to Meta + ..

Hearts in LibreOffice

LibreOffice has its own tools, which work no matter which desktop you use:

  1. Insert → Special Character, then type “heart” in the search box and double-click the one you want.
  2. Alt + X: in recent versions of LibreOffice Writer, type 2665 and press Alt + X to turn the code into ♥, just like in Microsoft Word.

If a heart looks wrong in your document, try a font with good symbol coverage, such as DejaVu Sans. The heart suit ♥ and empty heart ♡ pages explain the difference between the two classic text hearts.

Hearts in the terminal and code editors

  • bash: printf '\u2665\n' prints ♥ in a UTF-8 locale (bash 4.2+).
  • Vim: in insert mode, press Ctrl + V, then type u2665.
  • Python: print("\u2665") prints ♥.

Writing a paper? The heart symbol LaTeX guide covers \heartsuit and filled hearts.

Troubleshooting

  • Hearts show as boxes: install fonts with wide symbol coverage. On Debian and Ubuntu, fonts-noto-color-emoji adds color emoji, and DejaVu fonts cover the text hearts.
  • Ctrl + Shift + U opens something else: some apps (and some terminals) use that shortcut themselves. Use Compose or copy and paste instead.
  • Compose < 3 types something else: you may have pressed the keys together. Press each one separately, in order.
  • Emoji look black and white: your system lacks a color emoji font. Installing Noto Color Emoji usually fixes it.

For every heart’s code point and encoding, see the heart Unicode reference. For other operating systems, see how to type a heart symbol.

Frequently asked questions

How do I type a heart in Ubuntu?

Press Ctrl + Shift + U, type 2665 and press Enter or Space to get ♥. Use 2661 for ♡ and 2764 for ❤. This works in GTK apps and anywhere the IBus input method is active, which is the default on Ubuntu. For emoji hearts, open the Characters app or press Ctrl + . in GTK apps.

What is the Compose key sequence for a heart?

With a Compose key enabled, press Compose, then the less-than key <, then 3 to type ♥. Press the keys one after another rather than holding them. The sequence comes from the standard Compose table, so it works on most desktops, though custom keyboard setups can change it.

Why doesn't Ctrl + Shift + U work in my app?

Ctrl + Shift + U is provided by IBus and GTK. Some Qt or KDE apps, terminals and apps using other input methods may not support it, or may use the shortcut for something else. Try the Compose key, copy and paste from the Characters app, or switch the app's input method to IBus or Fcitx if it supports one.

How do I type a heart in the Linux terminal?

Most terminals accept pasted hearts, and many support Ctrl + Shift + U. In bash 4.2 or newer, printf '\u2665\n' prints ♥ in a UTF-8 locale. In Vim's insert mode, press Ctrl + V, then type u2665 to insert the same heart.

Related pages

Your text — tap hearts to add0