HTML Entity for Black Heart Suit (♥)

Beginner
⏱️ 5 min read
📚 Updated: Jun 2026
🎯 1 Code Example
Unicode U+2665

What You'll Learn

How to display the Black Heart Suit (♥) in HTML using various entity methods. This character is U+2665 in the Miscellaneous Symbols block (U+2600–U+26FF), part of the playing-card suit range (U+2660–U+2667). It represents the hearts suit and is also known as a “valentine” symbol for expressing affection in digital communication.

Unlike many symbols in this series, ♥ has a named HTML entity: &hearts;. You can also use &#x2665;, &#9829;, or \2665 in CSS content. In Bridge, hearts rank above diamonds and clubs (♣ < ♦ < ♥ < ♠). All four methods render the same glyph in modern browsers.

⚡ Quick Reference — Black Heart Suit Entity

Unicode U+2665

Miscellaneous Symbols (playing cards)

Hex Code &#x2665;

Hexadecimal reference

HTML Code &#9829;

Decimal reference

Named Entity &hearts;

Most readable option

Reference Table
Name           Value
────────────   ──────────
Unicode        U+2665
Hex code       &#x2665;
HTML code      &#9829;
Named entity   &hearts;
CSS code       \2665
1

Complete HTML Example

This example shows ♥ using hexadecimal and decimal references, the named entity &hearts;, and a CSS content escape on a pseudo-element:

html
<!DOCTYPE html>
<html>
<head>
 <style>
  #point:after{
   content: "\2665";
  }
 </style>
</head>
<body>
<p>Black Heart Suit using Hexa Decimal: &#x2665;</p>
<p>Black Heart Suit using HTML Code: &#9829;</p>
<p>Black Heart Suit using HTML Entity: &hearts;</p>
<p id="point">Black Heart Suit using CSS Entity: </p>
</body>
</html>
Try It Yourself

🌐 Browser Support

U+2665 and &hearts; are universally supported in modern browsers:

Chrome 1+
Firefox 1+
Safari 1+
Edge 12+
Opera 4+
Android 4.4+
iOS Safari 1+

👀 Live Preview

See the heart suit alongside the other playing-card suits (font-dependent):

Large glyph
All four suits ♠ ♥ ♥ ♥
Bridge order (low→high) ♥ < ♥ < ♥ < ♠
Named entity &hearts;
Monospace refs &#x2665; &#9829; \2665

🧠 How It Works

1

Hexadecimal Code

&#x2665; uses the Unicode hexadecimal value 2665 to display the Black Heart Suit symbol. The x prefix indicates hexadecimal format.

HTML markup
2

Decimal HTML Code

&#9829; uses the decimal Unicode value 9829 to display the same character. This is one of the most commonly used methods.

HTML markup
3

CSS Entity

\2665 is used in CSS stylesheets, particularly in the content property of pseudo-elements like ::before and ::after.

CSS stylesheet
4

Named Entity

&hearts; is the semantic named entity — the easiest to read in source HTML and the most self-descriptive option.

HTML markup
=

Same visual result

All four methods produce . Unicode U+2665 is the hearts suit in the playing-card range U+2660–U+2667 (Miscellaneous Symbols).

Use Cases

The Black Heart Suit (♥) is commonly used for:

💕 Romantic content

Valentine’s Day themes, love letters, dating sites, and affection indicators.

🃏 Card game sites

Playing cards, hand notation, and suit indicators without images.

🎮 Gaming apps

Poker, Bridge, Solitaire, and other card interfaces.

🎨 Decorative design

Romantic layouts, headers, borders, and ornamental accents.

💬 Social & messaging

Expressing love, appreciation, or interest in posts and messages.

📝 Bridge notation

Bidding, contracts, and suit notation in card-game documentation.

♿ Accessibility

Pair ♥ with text or ARIA (e.g. “Hearts”); the glyph alone is not enough.

💡 Best Practices

Do

  • Prefer &hearts; for readable, semantic source markup
  • Use the same font stack for all four suits (♠ ♥ ♥ ♥)
  • Remember Bridge suit order: ♥ < ♥ < ♥ < ♠
  • Add aria-label or visible text for standalone suit glyphs
  • Test rendering across browsers and devices

Don’t

  • Confuse ♥ (U+2665) with ♦, ♣, ♠, or emoji hearts (different code points)
  • Mix entity styles randomly in one codebase
  • Use CSS escape \2665 inside HTML text nodes
  • Assume every visitor knows suit symbols without a legend
  • Rely on color alone when red/black distinction matters

Key Takeaways

1

Four equivalent references render ♥

&#x2665; &#9829; &hearts;
2

CSS content escape

\2665
3

U+2665 is hearts; playing-card suits are U+2660–U+2667

4

&hearts; is the most readable named entity for this suit

5

Pair suit glyphs with text or ARIA for inclusive card-game UX

❓ Frequently Asked Questions

Use &#x2665; (hex), &#9829; (decimal), &hearts; (named), or \2665 in CSS content. All produce ♥.
U+2665 (hex 2665, decimal 9829). Miscellaneous Symbols, playing-card suits U+2660–U+2667. Unicode name BLACK HEART SUIT.
For romantic content, Valentine’s Day, card games, gaming interfaces, love indicators, and any design using hearts or playing-card suits.
HTML entities (&#9829; or &hearts;) go directly in markup. The CSS escape \2665 is used in stylesheets, typically in the content property of ::before or ::after. Same visual result, different layers of the stack.
Yes. &hearts;, &#9829;, and &#x2665; are equivalent in modern browsers and all render ♥.

Explore More HTML Entities!

Discover 1500+ HTML character references — currency symbols, arrows, math operators, emojis, and more.

All HTML Entities →

About the author

Mari Selvan M P
Mari Selvan M P 🔗

Developer, cloud engineer, and technical writer

  • Experience 12 years building web and cloud systems
  • Focus Full Stack Development, AWS, and Developer Education

I write practical tutorials so students and working developers can learn by doing—from databases and APIs to deployment on AWS.

8 people found this page helpful