How to Create a Heart Icon on Your Website

Build a Simple Heart Symbol Using HTML

There are two main ways to insert a heart symbol on your website. You can either copy the heart from elsewhere to easily paste it onto the page or you can learn what the HTML code is to make your own heart icon.

You can use CSS text styles to change the color of the heart symbol and font styles to change the size and weight (boldness) of the heart symbol.

HTML Heart Symbol

  1. With your website editor, open the page that should have the heart symbol, using editing mode instead of WYSIWYG mode.
  1. Put your cursor exactly where you want the symbol to be.
  2. Type the following within the HTML file:

    ♥
     
  3. Save the file and open it in a web browser to make sure it worked. You should see a heart like this: ♥

Copy and Paste the Heart Icon

Another way you can get the heart symbol to display is to simply copy and paste it from this page directly into your editor. However, not all browsers will reliably display it in this way.

Keep in mind that with WYSIWYG-only editors, you can copy and paste the heart symbol using the WYSIWYG mode, and the editor should convert it for you.