Heart-Shaped Name Art: Personalize with Ease

Jeffrey Jul 09, 2026

Ever wanted to add a touch of romance or playfulness to your text? You can now create names in a heart shape, a fun and engaging way to display names in your documents, social media posts, or even on your website. This article will guide you through the process, using simple HTML and CSS techniques.

a heart with flowers and the words your tex name in black ink on a white background
a heart with flowers and the words your tex name in black ink on a white background

Before we dive in, let's understand why you might want to put names in a heart shape. It could be for a Valentine's Day post, a wedding invitation, or simply to add a bit of whimsy to your content. Whatever the reason, it's a creative way to make your text stand out.

a metal heart with the words meghan and alex cristian all over it
a metal heart with the words meghan and alex cristian all over it

Using HTML and CSS to Create Heart-Shaped Names

HTML and CSS are powerful tools that allow you to manipulate text and create unique designs. To create heart-shaped names, we'll use the CSS `::before` pseudo-element and some creative positioning.

an image of hearts with names in the middle and two words below them, on a tablet
an image of hearts with names in the middle and two words below them, on a tablet

Here's a basic example to get us started:

Basic Heart-Shaped Name

two hearts that are connected to each other
two hearts that are connected to each other

First, let's create a simple heart shape. We'll use the `::before` pseudo-element to add a heart before the text. We'll use the `content` property to create the heart shape and `position` to position it correctly.

Here's the code:

<style>
  .heart::before {
    content: '♥';
    position: relative;
    left: -10px;
    top: -5px;
  }
</style>

<p class="heart">John</p>

Customizing the Heart Shape

19 Editable Name Tag & Name Badge Templates [Free]
19 Editable Name Tag & Name Badge Templates [Free]

Now that we have a basic heart shape, let's customize it. We can change the color, size, and even the type of heart used.

To change the color, we can use the `color` property. To change the size, we can use the `font-size` property. To change the type of heart, we can use different Unicode characters. Here are a few examples:

  • `♥` - Red Heart
  • `❤` - Black Heart
  • `♡` - White Heart
four hearts with names in the middle
four hearts with names in the middle

Creating Heart-Shaped Names with Multiple Words

So far, we've only created heart-shaped names with a single word. But what if you want to create heart-shaped names with multiple words, like "John Doe" or "Jane Smith"?

two hearts with flowers on them and the names of each couple in black and white
two hearts with flowers on them and the names of each couple in black and white
Cricut Design Space Tutorial Put Your Name in a Heart
Cricut Design Space Tutorial Put Your Name in a Heart
two hearts with names on them are drawn in the shape of three hearts, and one has
two hearts with names on them are drawn in the shape of three hearts, and one has
Oops!
Oops!
two hearts with names on the side of their thighs
two hearts with names on the side of their thighs
Custom Names Temporary Tattoo / Custom Words Tattoo / Custom Hearts Tattoo - Etsy
Custom Names Temporary Tattoo / Custom Words Tattoo / Custom Hearts Tattoo - Etsy
a piece of paper with writing on it and a heart drawn in the bottom corner
a piece of paper with writing on it and a heart drawn in the bottom corner
I will design an amazing word art in a heart shape | fonts music 275.49.6.10085
I will design an amazing word art in a heart shape | fonts music 275.49.6.10085
two hearts with names in the middle
two hearts with names in the middle
two hearts with names on them are in the shape of three hearts, one is black and
two hearts with names on them are in the shape of three hearts, one is black and
Name on Heart
Name on Heart
the back of a woman's arm with three hearts on it and words written in cursive writing
the back of a woman's arm with three hearts on it and words written in cursive writing
four hearts with the names of different people on them, all in black and white
four hearts with the names of different people on them, all in black and white
\
\
two heart tattoos with the words i love you written on them and an arrow in the middle
two heart tattoos with the words i love you written on them and an arrow in the middle
Personalized Wedding Place Names, Wedding Heart Shapes With Names
Personalized Wedding Place Names, Wedding Heart Shapes With Names
Custom Valentine Name, Heart Shape, Personalized Love Text, Matching Names. - Etsy
Custom Valentine Name, Heart Shape, Personalized Love Text, Matching Names. - Etsy
a black and white heart with the word name
a black and white heart with the word name
A Simple Diagram Of The Heart, Diagram Of Heart Anatomy, Labeled Labeled Easy Heart Diagram, Anatomy Easy Simple Human Heart Heart Diagram, Diagram Of Heart, Anatomical Heart Diagram, Simple Simple Labeled Heart Diagram, Heart Diagram Anatomy, Biology Biology Heart Diagram
A Simple Diagram Of The Heart, Diagram Of Heart Anatomy, Labeled Labeled Easy Heart Diagram, Anatomy Easy Simple Human Heart Heart Diagram, Diagram Of Heart, Anatomical Heart Diagram, Simple Simple Labeled Heart Diagram, Heart Diagram Anatomy, Biology Biology Heart Diagram
two hearts with the word married written in cursive writing on each one side
two hearts with the word married written in cursive writing on each one side

To do this, we can use the same technique, but we'll need to adjust the positioning to ensure the heart is centered correctly. We'll also need to add some space between the heart and the text to prevent them from overlapping.

Heart-Shaped Names with Multiple Words

Here's an example of how you can create heart-shaped names with multiple words:

<style>
  .heart-multi::before {
    content: '♥';
    position: relative;
    left: -15px;
    top: -5px;
    font-size: 2em;
  }

  .heart-multi::after {
    content: '';
    position: relative;
    left: 5px;
    top: -5px;
    font-size: 1em;
  }
</style>

<p class="heart-multi">John Doe</p>

The `::after` pseudo-element is used to add a space after the heart to prevent it from overlapping with the text.

Heart-Shaped Names with Different Colors for Each Word

For a more dynamic look, you can also create heart-shaped names with different colors for each word. Here's how you can do it:

<style>
  .heart-multi-colors::before {
    content: '♥';
    position: relative;
    left: -15px;
    top: -5px;
    font-size: 2em;
    color: red;
  }

  .heart-multi-colors::after {
    content: '';
    position: relative;
    left: 5px;
    top: -5px;
    font-size: 1em;
  }

  .heart-multi-colors span {
    color: blue;
  }
</style>

<p class="heart-multi-colors"><span>John</span> Doe</p>

In this example, we've used the `span` tag to wrap the second word and changed its color using the `color` property.

And there you have it! You now know how to create heart-shaped names using HTML and CSS. Whether you're creating a romantic post, a fun invitation, or just want to add a bit of whimsy to your text, heart-shaped names are a great way to make your content stand out. So go ahead, get creative, and have fun with it!