# No digits after X.

> Canonical HTML version: https://rocketvalidator.com/html-validation/no-digits-after-x
> Attribution: Rocket Validator (https://rocketvalidator.com)
> License: CC BY 4.0 (https://creativecommons.org/licenses/by/4.0/)

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 `&#169;`, or `&#x` followed by a hexadecimal number, such as `&#xA9;`. 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 `&copy;`. If you meant to show the characters `&#` on the page, escape the ampersand as `&amp;#`.

## Invalid example

```html
<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

```html
<p><span class="icon" aria-hidden="true">&#x1F6D2;</span> Cart</p>
<p>Type &amp;# and a number to insert a character by its code point.</p>
```
