Underscore (_)
U+005F · LOW LINE · Unicode 1.1 (1993)
How to type _
Windows
Alt code (numeric keypad)
Alt+95
Turn on Num Lock, hold the Alt key, type 95 on the numeric keypad and let go of Alt: _ appears.
Uses the old DOS code page 437, which US-English Windows uses for Alt codes without a leading 0; on Windows set to other languages the result can differ.
Word and Outlook: Alt + X
005F Alt+X
Type 005F and press Alt+X right after it: Word turns the code into _. Press Alt+X again to turn it back into the code.
Emoji and symbols panel (Windows 10 and 11)
Win+.
Press Win + full stop (.) to open the panel, go to the Symbols tab (Ω) and pick _.
No numeric keypad on your laptop? See the other ways in our Alt codes guide.
Mac
Character Viewer
Ctrl+⌘ Cmd+Space
Press Ctrl+⌘+Space (or the Globe key + E), search for “underscore” and click _ to insert it.
iPhone
Make a shortcut (Text Replacement)
Turn a short word into _ once and type it in any app:
- Copy _ from this page.
- Open Settings › General › Keyboard › Text Replacement and tap +.
- Paste _ as the Phrase and type a Shortcut, for example ;unders.
- Now type ;unders anywhere: the keyboard suggests _.
Android
Make a shortcut (Gboard personal dictionary)
Teach your keyboard a short word that turns into _:
- Copy _ from this page.
- Open Gboard settings › Dictionary › Personal dictionary, choose your language and tap +.
- Paste _ as the word and type a shortcut, for example ;unders.
- Type ;unders in any app and tap _ in the suggestions.
Linux
Unicode input
Ctrl+Shift+U 005f Enter
Press Ctrl+Shift+U, type 005f and press Enter or Space. Works in GTK apps and with IBus (GNOME, Ubuntu, Fedora).
What _ means and how it is used
The underscore _ was made for underlining on typewriters by backspacing over words. Today it joins words where spaces are not allowed: usernames, file names and variable names in snake_case. Instagram, TikTok and Discord usernames accept it, which makes it a favourite for nicknames like _ana_. It is Shift+Hyphen on most keyboards.
In Unicode, _ is code point U+005F with the official name LOW LINE. It belongs to the Basic Latin block and arrived with Unicode 1.1 in 1993.
Other words for it: dash, line, low, underdash, underline.
You will find it in our punctuation and typography symbols, 109 symbols in all, together with © ® ™ § ¶.
Codes for HTML, CSS and JavaScript
Tap Copy next to the code you need.
| HTML entity | _ | |
|---|---|---|
| HTML decimal | _ | |
| HTML hex | _ | |
| CSS | content: "\005F"; | |
| JavaScript | \u005F | |
| URL | _ | |
| UTF-8 bytes | 5F | |
| Unicode | U+005F |
Will it show on my friend's phone?
Very likely yes: _ dates from Unicode 1.1 (1993), so every current system has a font for it.
Checking your device…
Don't confuse _ with
These look alike but are different characters. Search, sorting and screen readers treat them differently, so copy the one you mean.
- _UnderscoreU+005F · LOW LINE
- Wavy low lineU+FE4F · WAVY LOW LINE · CJK Compatibility Forms
- Fullwidth low lineU+FF3F · FULLWIDTH LOW LINE · Halfwidth and Fullwidth Forms
- ـU+0640 · Arabic
- ߺU+07FA · NKo
- ﹍U+FE4D · CJK Compatibility Forms
- ﹎U+FE4E · CJK Compatibility Forms
Names in other languages
What _ is called in the 12 languages of this site (Unicode CLDR and our editors). Tap a name to open that language's page.
| Language | Name |
|---|---|
| English | Underscore |
| Português | Underline (sublinhado) |
| Español | Guion bajo |
| Italiano | Trattino basso (underscore) |
| Français | Tiret bas (underscore) |
| Deutsch | Unterstrich |
| Türkçe | Alt çizgi |
| Bahasa Indonesia | Garis bawah (underscore) |
| Polski | Podkreślnik |
| Русский | Нижнее подчёркивание |
| 日本語 | アンダーバー |
| 한국어 | 밑줄 (언더스코어) |
Related symbols
All Punctuation →Questions people ask
How do I type _ on a laptop without a numeric keypad?
On Windows press Win + full stop (.) and pick _ in the Symbols tab, or in Word type 005F and press Alt+X.
What is the difference between _ and ﹏?
_ is the underscore (U+005F). ﹏ is a different character: wavy low line (U+FE4F, CJK Compatibility Forms block). They can look alike, but computers treat them as different letters, so a search for one will not find the other.
How do I type _ on an iPhone?
The iPhone keyboard has no key for _. Copy it here, then add it in Settings › General › Keyboard › Text Replacement with a shortcut like ;unders.
What is the HTML code for the underscore?
Use the entity _ or the numeric code _ (hex _). In CSS write \005F, in JavaScript \u005F.
Will _ show on every phone?
Very likely yes: _ dates from Unicode 1.1 (1993), so every current system has a font for it.