More
More
Soft Hyphen HTML entity ­
­ is the HTML entity for Soft Hyphen (U+00AD). Copy the decimal ­ and hex ­ codes plus CSS, JavaScript, Python and URL escapes.
- Entity
­- Legacy form
­(no semicolon)- Code point
- U+00AD
- Unicode name
- SOFT HYPHEN
- Block
- Latin-1 Supplement
- Category
- Format (Cf)
- Since
- Unicode 1.1
- Defined in
- HTML 4.01 and HTML5
Codes to copy
| HTML named | ­Works in HTML; in XML only & < > " ' are predefined. | |
|---|---|---|
| HTML decimal | ­Works in HTML and XML. | |
| HTML hex | ­Works in HTML and XML. | |
| CSS | content: "\AD";In a stylesheet, for ::before and ::after. | |
| JavaScript | "\u00AD"Also valid in JSON. | |
| Python | "\u00ad"Python 3 string literal. | |
| Python by name | "\N{SOFT HYPHEN}"Readable alternative using the Unicode name. | |
| URL | %C2%ADPercent-encoded UTF-8 bytes, for a path or query value. | |
| UTF-8 bytes | C2 AD2 bytes. | |
| UTF-16 | 00AD1 code unit, which is what JavaScript length counts. |
When to use it
An invisible hint that a long word may break at that point. Nothing shows unless the browser breaks the line there, when a hyphen appears. CSS hyphens: auto hyphenates whole texts automatically for languages the browser knows.
The name dates from HTML 4, so it works in every browser and in old email clients.
Browsers also accept the legacy form ­ without a semicolon, for compatibility with old pages; new HTML should always end the reference with a semicolon.
It has no visible shape of its own, which is why the box above shows it with a tinted background.
More spaces and invisible characters
 En Space Non-Breaking Space Em Space
Line Feed Three-Per-Em Space	Tab Character Four-Per-Em Space Figure Space
All spaces and invisible characters · Every HTML entity · Encode or decode text
Source: the WHATWG HTML Standard list of named character references and the Unicode Character Database (Unicode 18.0).