HTML Entity for Macron (Combining)

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

What Is the Combining Macron Entity?

Combining macron is the Combining Diacritical Marks character at Unicode U+0304 (COMBINING MACRON). It is a non-spacing mark placed immediately after a base letter to add a flat bar above it — often for long vowels, phonetics, or statistical overlines.

Remember
Character     ◌̄ (on base letter)
Unicode       U+0304
Hex entity    ̄
Decimal       ̄
CSS escape    \0304
Named entity  (none)

Hex, decimal, and CSS all produce the same combining mark. Write it right after the base letter (ā → ā). Prefer precomposed letters like ā when they exist.

Quick Reference

One table for every form you will actually use.

FormCodeWhere it goes
Hex entitȳHTML markup (after base letter)
Decimal entitȳHTML markup (after base letter)
CSS escape\0304Stylesheet content
Named entity—Not defined in HTML5
Precomposed (preferred)ā, ū, …When a single code point exists

When to Use Which

SituationUse
Letter already has a precomposed form (ā, ē, ū, …)Named entity (e.g. ā)
Need a combining mark on any base letter̄ or ̄ after the letter
Generated text via ::before / ::aftercontent: "\0304"
Standalone bar character (own width)Spacing macron — see Spacing Macron (¯)
Bar under the letterSee Macron Below (U+0331)

Live Preview

Combining macron applied in common study contexts.

On vowels ā ē ī ō ū
Large glyph ā
Statistics x̄ = sample mean
vs spacing / below ā  |  ¯  |  a̱
With entities Hex: ā | Decimal: ē

Complete HTML Example

One page that shows the combining macron with hex, decimal, and CSS forms. Use View Output or open the live editor.

Hex + Decimal + CSS

Three ways to attach U+0304 to a base letter in one document.

html
<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <title>Combining Macron (U+0304)</title>
  <style>
    #point::after {
      content: "\0304";
    }
  </style>
</head>
<body>
  <p>Using Hex Code: a&#x0304;</p>
  <p>Using HTML Code: e&#772;</p>
  <p>x<span id="point"></span> (CSS macron on x)</p>
  <p>Prefer precomposed when possible: &amacr;</p>
</body>
</html>
Try It Yourself

How It Works

1. Hex: U+0304 → &#x0304; right after a. The browser combines them into ā.

2. Decimal: same code point as 772 → &#772; after e. Same combining mark.

3. CSS: use \0304 in content (not an HTML entity). #point::after appends the mark after x, producing x̄.

4. Precomposed: &amacr; is a single character (U+0101). Prefer it when the letter you need already exists.

Pitfalls & Tips

Common mistakes when working with the combining macron.

Order

Base letter first

Write a&#x0304;, not &#x0304;a. The mark attaches to the preceding character.

Named?

No &macron;

HTML5 does not define a named entity for U+0304. Use numeric forms.

Look-alikes

Not spacing macron

U+00AF (&macr;) is a standalone bar. U+0304 combines with a letter.

Compose

Prefer precomposed

Use &amacr; / &umacr; when available — simpler markup and better searchability.

CSS vs HTML

Do not mix escapes

\0304 belongs in CSS. &#x0304; / &#772; belong in HTML.

Semicolon

End references

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

Browser Support

Combining macron (U+0304) and its numeric entity forms (&#x0304;, &#772;, CSS \\0304) are supported in all mainstream browsers with a Unicode-capable font.

✓ Universal support

Combining Macron (U+0304)

Encode with hex, decimal, or CSS escape — place after the base letter for the same combining mark.

100% Browser coverage
Google Chrome Supported
Yes
Microsoft Edge Supported
Yes
Mozilla Firefox Supported
Yes
Apple Safari Supported
Yes
Opera Supported
Yes
Internet Explorer IE 9+
Yes*
U+0304 / entities Full support

Bottom line: Prefer precomposed letters when available. Use &#x0304; or &#772; after a base letter when you need the combining mark, and \\0304 only inside CSS content.

Key Takeaways

  • Unicode: combining macron is U+0304 (decimal 772).
  • HTML: use &#x0304; or &#772; immediately after the base letter.
  • CSS: use \0304 inside content for generated text.
  • Default: prefer precomposed letters (&amacr;, etc.) when they exist.

One line: U+0304 → place &#x0304; / &#772; / CSS \0304 after the base letter.

Frequently Asked Questions

Use &#x0304; (hex), &#772; (decimal), or the CSS escape \0304 in the content property. Place the entity immediately after the base letter (e.g. a&#x0304; for ā). There is no named HTML entity for U+0304.
U+0304 (COMBINING MACRON). Hex 0304, decimal 772. It belongs to the Combining Diacritical Marks block (U+0300–U+036F).
No. U+0304 has no named HTML entity. Use numeric references like &#x0304; or &#772;. Prefer precomposed letters such as &amacr; (ā) when a single code point exists.
Use it for linguistic notation, phonetic transcription, transliteration (Māori, Hawaiian, Latin), dictionary guides, and statistical overlines (x̄). Prefer precomposed characters when available.
HTML entities (&#772; or &#x0304;) go in markup after the base character. The CSS escape \0304 is used in stylesheets (usually in the content property of ::before/::after). Both render the same combining mark.
U+0304 is a non-spacing mark that attaches to the previous letter. U+00AF (spacing macron, &macr;) is a standalone character that occupies its own width.

Did you know?

Combining macron is Unicode U+0304 (decimal 772) — COMBINING MACRON in Combining Diacritical Marks. HTML5 has no named entity for it — use &#x0304; or &#772; right after a base letter. Prefer precomposed forms like &amacr; (ā) when available.

Next: Macron Below

Learn the HTML entity for combining macron below (U+0331) — a bar under the base letter.

Macron Below 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