HTML Entity for Non-Breaking Hyphen (‑)

Beginner
6 min read
Updated: Sep 2026
1 example
Unicode U+2011

What Is the Non-Breaking Hyphen Entity?

Non-breaking hyphen (‑) is the General Punctuation character at Unicode U+2011 (NON-BREAKING HYPHEN). It looks like a normal hyphen but prevents a line break at that position — useful in hyphenated words, codes, and headlines. HTML5 defines no named entity for it.

Remember
Character     ‑
Unicode       U+2011
Named entity  (none)
Hex entity    ‑
Decimal       ‑
CSS escape    \2011

All of these produce the same glyph: ‑. Prefer a pasted ‑ in UTF-8 pages; use numeric or CSS forms when you need an escape.

Quick Reference

One table for every form you will actually use.

FormCodeWhere it goes
Direct character‑HTML text (UTF-8 default)
Named entitynoneNot defined in HTML5
Hex entity‑HTML markup
Decimal entity‑HTML markup
CSS escape\2011Stylesheet content

When to Use Which

SituationUse
Hyphenated text that must stay on one line‑ or paste ‑
Normal hyphen (wrapping OK)Type - (U+002D)
Optional hyphenation hint­ (U+00AD)
Non-breaking space  (U+00A0) — see Related Topics
Generated text via ::before / ::aftercontent: "\2011"

Live Preview

Non-breaking hyphen rendered in common contexts.

Glyph ‑
Large glyph ‑
In a word non‑breaking
With entities Hex: ‑ | Decimal: ‑
Related - (U+002D) · ­ ·  

Complete HTML Example

One page that shows the non-breaking hyphen with hex, decimal, direct, and CSS forms. Use View Output or open the live editor.

Hex + Decimal + Direct + CSS

Four ways to produce ‑ in a single document (no named entity).

html
<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <title>Non-Breaking Hyphen (‑) in HTML</title>
  <style>
    #point::after {
      content: "\2011";
    }
  </style>
</head>
<body>
  <p>Using Hex Code: &#x2011;</p>
  <p>Using HTML Code: &#8209;</p>
  <p>Using Direct Character: ‑</p>
  <p id="point">Using CSS Entity: </p>
  <p>Example: non&#x2011;breaking</p>
</body>
</html>
Try It Yourself

How It Works

1. Hex: U+2011 → &#x2011; in HTML. Reliable numeric form.

2. Decimal: same code point as 8209 → &#8209;. Same glyph.

3. Direct: paste ‑ in a UTF-8 file with <meta charset="UTF-8">.

4. CSS: use \2011 in content (not an HTML entity). #point::after appends that ‑ after the paragraph text.

Pitfalls & Tips

Common mistakes when working with the non-breaking hyphen.

Named

No named entity

HTML5 has no &... name for U+2011 — use hex or decimal instead (unlike &nbsp; for spaces).

Not &nbsp;

Hyphen vs space

‑ keeps a hyphenated join together. &nbsp; keeps a space from wrapping. Different jobs.

Look-alikes

Not - or &shy;

ASCII - (U+002D) may allow a break. Soft hyphen &shy; suggests an optional break. Non-breaking hyphen forbids the break.

CSS vs HTML

Do not mix escapes

\2011 belongs in CSS. &#x2011; / &#8209; belong in HTML.

Semicolon

End references

Always finish with ; — write &#8209;, not &#8209.

UTF-8

Declare charset

If you paste ‑ directly, serve the page as UTF-8 with <meta charset="UTF-8">.

Browser Support

Non-breaking hyphen (U+2011) and its entity forms (&#x2011;, &#8209;, CSS \\2011) are supported in all mainstream browsers. Line-break behavior follows Unicode rules; glyph availability depends on the font.

✓ Universal support

Non-Breaking Hyphen (‑)

Paste ‑, or encode with hex, decimal, or CSS escape — same glyph everywhere. No named entity.

100% Browser coverage
Google Chrome Supported
Yes
Microsoft Edge Supported
Yes
Mozilla Firefox Supported
Yes
Apple Safari Supported
Yes
Opera Supported
Yes
Internet Explorer All versions
Yes
U+2011 / entities Full support

Bottom line: Prefer a pasted ‑ in UTF-8 text. Use &#x2011; / &#8209; when a numeric form is required, and \\2011 only inside CSS content.

Key Takeaways

  • Unicode: non-breaking hyphen is U+2011 (decimal 8209), General Punctuation.
  • HTML: no named entity — use &#x2011; or &#8209;.
  • CSS: use \2011 inside content for generated text.
  • Use: keep hyphenated joins together — not the same as -, &shy;, or &nbsp;.

One line: U+2011 → &#x2011; / &#8209; / CSS \2011 (no named entity).

Frequently Asked Questions

Use &#x2011; (hex), &#8209; (decimal), type ‑ in UTF-8, or the CSS escape \2011 in content. There is no HTML5 named entity for U+2011.
U+2011 (NON-BREAKING HYPHEN). Hex 2011, decimal 8209. It belongs to General Punctuation and prevents a line break at the hyphen.
No. HTML5 does not define a named entity for this character. Use numeric references like &#8209; or &#x2011; when you need an entity form.
Use it in hyphenated words or codes that must stay on one line (e.g. non‑breaking, product IDs). Prefer a regular hyphen (-) when wrapping is fine. Use &nbsp; when you need a non-breaking space, not a hyphen.
HTML entities (&#8209; or &#x2011;) go in markup. The CSS escape \2011 is used in stylesheets (usually in the content property of ::before/::after). Both render ‑.
Hyphen-minus (-) is U+002D and may allow a break. Soft hyphen (&shy;, U+00AD) is an optional break hint. Non-breaking space (&nbsp;, U+00A0) keeps spaces from wrapping. ‑ specifically keeps a hyphenated join from wrapping.

Did you know?

Non-breaking hyphen (‑) is Unicode U+2011 (decimal 8209) — NON-BREAKING HYPHEN in General Punctuation. HTML5 has no named entity — use &#x2011; or &#8209;. It looks like a hyphen but blocks a line break at that position. For spaces that must not wrap, use &nbsp; (U+00A0) instead.

Next: Non-Breaking Space

Learn the HTML entity for the non-breaking space — the next character in this entity sequence.

Non-Breaking Space tutorial →

CODETOFUN NEWS

Stay Ahead in Tech

Get the latest IT news, programming updates, and technology trends directly on your phone.

Your daily dose of tech, straight to your feed.

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