HTML Guides for digits
Learn how to identify and fix common HTML validation errors flagged by the W3C Validator — so your pages are standards-compliant and render correctly across every browser. Also check our Accessibility Guides.
A numeric character reference starts with &# but has no digits after it, so the parser can't turn it into a character.
Numeric character references come in two forms: &# followed by a decimal number, such as ©, or &#x followed by a hexadecimal number, such as ©. Both end with a semicolon. When the parser reads &# or &#x and the next character isn't a digit, it reports this error and keeps those characters as plain text, so &#; shows up on the page exactly as typed.
The quoted part of the message is the text that comes before &# in the same attribute value. For a reference in text content there is no preceding text, so the quotes are empty. Two common causes are a template that builds a reference from an empty variable, such as an icon font code point, and a literal &# in text or in a URL that was never escaped.
To fix it, put the code point of the character you want between &# and the semicolon, or use a named reference like ©. If you meant to show the characters &# on the page, escape the ampersand as &#.
Invalid example
<p><span class="icon" aria-hidden="true">&#x;</span> Cart</p>
<p>Type &# and a number to insert a character by its code point.</p>
Valid example
<p><span class="icon" aria-hidden="true">🛒</span> Cart</p>
<p>Type &# and a number to insert a character by its code point.</p>
Validate at scale.
Ship accessible websites, faster.
Automated HTML & accessibility validation for large sites. Check thousands of pages against WCAG guidelines and W3C standards in minutes, not days.
1K Weekly
1,000 monthly checks. Cancel anytime.
Get 1K Weekly →Join teams across 40+ countries