HTML Entity for Complement (∁)

Beginner
⏱️ 5 min read
📚 Updated: Jun 2026
🎯 1 Code Example
Unicode U+2201

What You'll Learn

How to display the Complement (∁) symbol in HTML using numeric references, the named entity, and CSS escapes. This character is U+2201 (COMPLEMENT) in the Mathematical Operators block (U+2200–U+22FF). It denotes the complement of a set in set theory and appears in logic and mathematical documentation.

Use the named entity ∁, hex ∁, decimal ∁, or CSS \2201. ∁ is the most readable option when writing HTML by hand. Do not confuse ∁ with Commercial Minus Sign U+2052 (⁒) or punctuation Colon U+003A (:).

⚡ Quick Reference — Complement

Unicode U+2201

Mathematical Operators (U+2200–U+22FF)

Hex Code ∁

Hexadecimal reference

HTML Code ∁

Decimal reference

Named Entity ∁

Standard HTML entity

Reference Table
Name           Value
────────────   ──────────
Unicode        U+2201
Hex code       ∁
HTML code      ∁
Named entity   ∁
CSS code       \2201
1

Complete HTML Example

This example demonstrates the Complement (∁) using hexadecimal code, decimal HTML code, the named entity ∁, and a CSS content escape:

html
<!DOCTYPE html>
<html>
<head>
 <style>
  #point:after{
   content: "\2201";
  }
 </style>
</head>
<body>
<p>Complement using Hexa Decimal: &#x2201;</p>
<p>Complement using HTML Code: &#8705;</p>
<p>Complement using HTML Entity: &comp;</p>
<p id="point">Complement using CSS Entity: </p>
</body>
</html>
Try it Yourself

🌐 Browser Support

U+2201 is supported in modern browsers; use a math-capable font for best glyph quality:

Chrome 1+
Firefox 1+
Safari 3.1+
Edge 12+
Opera 4+
Android 4.4+
iOS Safari 3.2+

👀 Live Preview

See the Complement symbol in mathematical contexts:

Set theory ∁A = elements not in A
Named entity &comp;B
Standalone
Logic docs Boolean complement ∁x
Monospace refs &#x2201; &#8705; &comp; \2201

🧠 How It Works

1

Hexadecimal Code

&#x2201; references code point U+2201 using hex digits 2201.

HTML markup
2

Decimal HTML Code

&#8705; is the decimal equivalent (8705) for the same character.

HTML markup
3

Named HTML Entity

&comp; is the standard named entity for U+2201—easy to remember for set complement notation.

HTML markup
4

CSS Entity

\2201 is the CSS escape for U+2201, used in the content property of ::before or ::after.

CSS stylesheet
=

Same visual result

All four methods produce the Complement glyph: . Unicode U+2201 sits in Mathematical Operators (U+2200–U+22FF).

Use Cases

The Complement symbol (∁) commonly appears in:

📊 Set theory

Denote the complement of a set (e.g. ∁A for the complement of set A).

📚 Math education

Online courses, textbooks, and lecture notes on discrete mathematics.

🔢 Logic & Boolean algebra

Formal logic, Boolean algebra, and computer science documentation.

📄 Technical docs

API references, white papers, and specification documents with math notation.

💻 Generated HTML

CMS or tools that output math symbols without MathML.

🔤 Symbol references

Unicode tables and Mathematical Operators glossaries.

♿ Accessibility

Provide surrounding text or aria-label so assistive tech conveys set-complement meaning.

💡 Best Practices

Do

  • Prefer &comp; for readable hand-written HTML
  • Use math fonts (Cambria Math, STIX Two Math) for clear operator glyphs
  • Keep entity style consistent across a document
  • Use \2201 only inside CSS content
  • Consider MathML or LaTeX for complex equations; entities work for inline symbols

Don’t

  • Confuse U+2201 (∁) with Commercial Minus U+2052 (⁒)
  • Use a regular hyphen or minus sign instead of ∁ in formal set notation
  • Assume every system font renders Mathematical Operators clearly
  • Put CSS escape \2201 in HTML text nodes
  • Mix entity styles randomly in one file

Key Takeaways

1

Named entity is easiest to remember

&comp;
2

Numeric references also render ∁

&#x2201; &#8705;
3

For CSS stylesheets, use the escape in the content property

\2201
4

U+2201 COMPLEMENT (Mathematical Operators)

5

Four methods, one glyph — widely supported in modern browsers

❓ Frequently Asked Questions

Use &comp; (named entity), &#x2201; (hex), &#8705; (decimal), or \2201 in CSS content. All four methods render ∁.
U+2201 (COMPLEMENT). Mathematical Operators (U+2200–U+22FF). Hex 2201, decimal 8705.
When you need the complement-of-a-set symbol in set theory, mathematical notation, logic, Boolean algebra, or technical documentation. &comp; is the most readable option when writing HTML by hand.
HTML entities (&comp;, &#8705;, or &#x2201;) go directly in markup. The CSS escape \2201 is used in stylesheets, typically in the content property of pseudo-elements.
Yes. &comp; is the named entity for U+2201. It is well supported and maps to the set-complement operator ∁.

Explore More HTML Entities!

Discover 1500+ HTML character references — math operators, symbols, arrows, and more.

All HTML Entities →

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