Punctuation & Typography

Low Line _

U+005F Added in Unicode 1.1 (1993) Formerly “spacing underscore”

The underscore is a punctuation mark, a horizontal line placed below the text baseline, often used as a spacer or connector.

Codes
Unicode
Unicode name
Decimal
HTML entity
HTML decimal
HTML hex
Encodings & code escapes +
UTF-8 (hex bytes)
UTF-16 (hex units)
UTF-32
URL encoded
CSS content
JavaScript / TypeScript
JSON, Java, C#, C/C++
Python
Go
Rust, Swift, PHP, Ruby
Perl

Click any value to copy it. All escapes refer to the same code point U+005F.

How to type _ on Windows

The low line symbol has no short Alt code. The quickest option is to copy it from the top of this page and paste it with Ctrl+V.

No numeric keypad?

Press Win+. to open the emoji panel, choose the Symbols tab (Ω) and search for "low line". Or open Character Map from the Start menu, find _, click Select, then Copy.

How to type _ on a Mac

There is no direct keyboard shortcut for _ on a Mac.

For any symbol, the Character Viewer works: press Control+⌘+Space, type "low line" in the search box and double-click the result. It will be remembered under Frequently Used.

How to type _ on iPhone and iPad

The iOS keyboard does not include _, so the reliable way is to copy it from this page, then press and hold in any text field and tap Paste.

If you use it often, create a shortcut: open Settings → General → Keyboard → Text Replacement, paste _ in the Phrase field and type a short code such as ;low in the Shortcut field. Typing that code will then insert _ anywhere.

How to type _ on Android

Copy the symbol from this page, then long-press in a text field and choose Paste. Gboard also keeps a clipboard history: tap the clipboard icon on the toolbar to paste it again later.

For a permanent shortcut, open Gboard settings → Dictionary → Personal dictionary, add _ as the word and a short code as the shortcut.

How to type _ in Microsoft Word

  1. Type the Unicode hex code 005F where you want the symbol.
  2. Press Alt+X. Word converts the code into _.

This works on Windows in Word, Outlook and OneNote and needs no numeric keypad. You can also go to Insert → Symbol → More Symbols, set the font to a Unicode font and type 005F in the Character code box. In Excel, the formula =UNICHAR(95) returns the symbol.

How to type _ in Google Docs

Open Insert → Special characters, then either search for "low line" or draw the symbol in the sketch box. Click the result to insert it. In Google Sheets, use =CHAR(95).

_ in HTML, CSS and code

FormatCode
HTML entity_
HTML decimal_
HTML hex_
CSS content"\005F"
JavaScript"\u005F"
Python"\u005F"
URL encoded_

Because _ is a standard Unicode character (U+005F), you can also paste it directly into any UTF-8 file. The escaped forms above are only needed when the file encoding is uncertain or the symbol must be entered on a keyboard without it.

Where the low line symbol is used

It appears in programming and file names where spaces are not allowed, such as "user_name" or "my_file.txt", and in social media handles like "jane_doe". It is sometimes confused with the hyphen or minus sign, which sit higher on the line.

Frequently asked questions

What is the underscore used for in usernames? +

It replaces spaces in usernames and handles since most systems do not allow blank spaces, letting people separate words like "john_smith".

Is underscore the same as a dash? +

No, the underscore sits below the baseline as a spacer, while a dash or hyphen sits mid-line and usually connects or separates words.

What is the Alt code for the low line symbol? +

The low line symbol has no short Alt code. Copy it from this page, or in Word type 005F and press Alt + X.

How do I type _ on a Mac? +

There is no dedicated Mac shortcut for _. Open the Character Viewer with Control + Command + Space, search for "low line", and double-click it. Or copy it from this page.

How do I type the low line symbol on iPhone or Android? +

Phone keyboards do not include _ by default. Copy it from this page and paste it, or add it as a text replacement shortcut in Settings so you can type it with a short abbreviation.

What is the HTML code for _? +

Use _ in HTML. The numeric form _ works too. In CSS use content: "\005F" and in JavaScript use "\u005F".

✓ Copied to clipboard