─ is the Unicode character BOX DRAWINGS LIGHT HORIZONTAL, code point U+2500 (decimal 9472) in the Box Drawing block, added in Unicode 1.1. In HTML write ─, and in UTF-8 it is the 3 bytes E2 94 80.
Codes
| Where | How to write it |
|---|---|
| Code point | U+2500 |
| Decimal | 9472 |
| UTF-8 bytes | E2 94 80 |
| UTF-16 (big-endian) | 2500 |
| UTF-32 | 00002500 |
| HTML decimal | ─ |
| HTML hex | ─ |
| HTML named | ─ ─ |
| CSS | \2500 |
| JavaScript | \u2500 |
| JSON | \u2500 |
| Python | \u2500 |
| Python by name | \N{BOX DRAWINGS LIGHT HORIZONTAL} |
| Java, C# | \u2500 |
| Rust, Swift | \u{2500} |
| Go, C, C++ | \u2500 |
| URL (percent-encoded) | %E2%94%80 |
JavaScript and JSON strings store text as UTF-16, so this character is one code unit long. Python 3 strings count code points, so its length there is 1.
Properties
| Property | Value |
|---|---|
| Name | BOX DRAWINGS LIGHT HORIZONTAL |
| Code point | U+2500 (decimal 9472) |
| Block | Box Drawing (U+2500–U+257F) |
| General category | So: Other symbol |
| Script | Common |
| Bidirectional class | ON: Other neutral |
| Mirrored in right-to-left text | No |
| First in Unicode version | 1.1 |
Nearby in Box Drawing
- ━ U+2501 Box Drawings Heavy Horizontal
- │ U+2502 Box Drawings Light Vertical
- ┃ U+2503 Box Drawings Heavy Vertical
- ┄ U+2504 Box Drawings Light Triple Dash Horizontal
- ┅ U+2505 Box Drawings Heavy Triple Dash Horizontal
- ┆ U+2506 Box Drawings Light Triple Dash Vertical
- ┇ U+2507 Box Drawings Heavy Triple Dash Vertical
- ┈ U+2508 Box Drawings Light Quadruple Dash Horizontal
All 128 characters: Box Drawing.
Official reference
Questions people ask
- What is the HTML code for ─?
- Use the named entity ─, or ─ (decimal) or ─ (hex).
- What is the UTF-8 encoding of U+2500?
- E2 94 80 (hex), 3 bytes. In a URL it is %E2%94%80.
- How do I write U+2500 in JavaScript or Python?
- JavaScript: \u2500. Python: \u2500.
Source
Unicode Character Database 18.0.0 (Unicode License v3); HTML entity names from the WHATWG HTML Standard (CC BY 4.0). The encodings above are computed from the code point and checked against Python's encoders. How the character looks depends on your fonts.
Legal entity
Devansh Yadav
Moradabad, Uttar Pradesh
Governing law: Courts at Moradabad, Uttar Pradesh
Phone: +91 8433475698
Legal: legal@analyzeit.in