HTML Entity for Digit Six (6)

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

What Is the Digit Six Entity?

Digit six (6) is the Basic Latin character at Unicode U+0036. You can type 6 directly in HTML, or write it with a numeric character reference when you need an explicit entity form.

Remember
Character     6
Unicode       U+0036
Hex entity    6
Decimal       6
CSS escape    \0036
Named entity  (none)

All of these produce the same glyph: 6. Prefer typing 6 in normal page text; use entities for CSS content, generated markup, or when encoding must be explicit.

Quick Reference

One table for every form you will actually use.

FormCodeWhere it goes
Direct character6HTML text (default choice)
Hex entity6HTML markup
Decimal entity6HTML markup
CSS escape\0036Stylesheet content
Named entity—Not defined in HTML5

When to use which

SituationUse
Normal paragraphs, headings, labelsType 6
Need an entity in HTML source6 or 6
Generated text via ::before / ::aftercontent: "\0036"
Looking for &six; or similarDoes not exist — use numeric form

Live Preview

Digit six rendered in common UI contexts.

Inline text You have 6 unread emails.
Large glyph 6
Date / time 2026-06-16 16:06
Monospace index 6, value 6
With entities Hex: 6 | Decimal: 6

Complete HTML Example

One page that shows digit six with the hex entity, decimal entity, CSS escape, and a typed character. Use View Output or open the live editor.

Hex + Decimal + CSS + Typed

All four ways to produce 6 in a single document.

html
<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <title>Digit Six (6) in HTML</title>
  <style>
    #point::after {
      content: "\0036";
    }
  </style>
</head>
<body>
  <p>Digit Six using Hex Code: &#x36;</p>
  <p>Digit Six using HTML Code: &#54;</p>
  <p id="point">Digit Six using CSS Entity: </p>
  <p>Typed directly: 6</p>
</body>
</html>
Try It Yourself

How It Works

1. Hex: U+0036 → &#x36; in HTML. The browser turns it into 6.

2. Decimal: same code point as 54 → &#54;. Same result as hex.

3. CSS: use \0036 in content (not an HTML entity). #point::after appends that 6 after the paragraph text.

4. Typed 6: best for normal text. All four lines show the same digit.

Pitfalls & Tips

Common mistakes when working with digit six entities.

Named?

No &six;

HTML5 does not define a named entity for ASCII digits. Use numeric forms.

CSS vs HTML

Do not mix escapes

\0036 belongs in CSS. &#x36; / &#54; belong in HTML.

Lookalikes

Related forms differ

Circled or dingbat sixes (such as ➅) are different Unicode characters — not the same as U+0036.

Default

Type 6 when you can

Entities are for encoding needs — not required for ordinary body text.

Semicolon

End references

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

CSS escape

Pad short hex

In CSS content, prefer \0036 (six hex digits) so the escape does not swallow the next character.

Browser Support

Digit six (U+0036) and its numeric entity forms (&#x36;, &#54;, CSS \\0036) are supported in all mainstream browsers.

✓ Universal support

Digit Six (6)

Type 6, or encode with hex, decimal, or CSS escape — same glyph everywhere.

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+0036 / entities Full support

Bottom line: Use a typed 6 for normal text. Prefer &#x36; or &#54; in HTML when encoding must be explicit, and \\0036 only inside CSS content.

Key Takeaways

  • Unicode: digit six is U+0036 (decimal 54).
  • HTML: use &#x36; or &#54; when you need an entity.
  • CSS: use \0036 inside content for generated text.
  • Default: type 6 directly unless encoding requires an entity.

One line: U+0036 → type 6, or encode as &#x36; / &#54; / CSS \0036.

Frequently Asked Questions

Use &#x36; (hex), &#54; (decimal), or the CSS escape \0036 in the content property. All render the digit six (6). In most cases you can also type 6 directly.
U+0036 (hex 0036, decimal 54). It belongs to the Basic Latin (ASCII) block.
No. ASCII digits like 6 do not have named HTML entities in HTML5, so you should use numeric references like &#54; or &#x36; when you need an entity form.
Use entities when generating content in CSS, when you want explicit encoding, or when outputting into contexts where escaping is required. For normal body text, typing 6 directly is usually best.
HTML entities (&#54; or &#x36;) go in markup. The CSS escape \0036 is used in stylesheets (usually in the content property of ::before/::after). Both render 6.
No. Digit six is U+0036. Circled and other stylized sixes (such as dingbat circled sans-serif ➅) are different Unicode characters.

Did you know?

Digit six is Unicode U+0036 (decimal 54). HTML5 has no named entity for it — use &#x36; or &#54; when you need an entity form.

Next: 6 Dingbat Circled Sans Serif

Learn the HTML entity for dingbat circled sans-serif digit six (➅) — a different Unicode character from digit six.

6 Dingbat Circled Sans Serif tutorial →

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