How to type Underscore _
Pick your device.
| Char | How to type it |
|---|---|
| _ | Press Shift + - (the minus key, right of 0). |
| _ | Or hold Alt and type 95 on the number pad. |
| Char | How to type it |
|---|---|
| _ | Press Shift + -. |
| Char | How to type it |
|---|---|
| _ | Tap 123, then #+= (iPhone) or =\< (Android) and tap _. |
| Char | How to type it |
|---|---|
| _ | Press Shift + -. |
| Char | How to type it |
|---|---|
| _ | On UK and most European keyboards it is also Shift + the key right of 0. |
What is an underscore?
The line that sits on the baseline.
The underscore ( _ ), officially called the low line, is a horizontal line that sits at the bottom of the text line. It started on typewriters, where people typed it over words to underline them.
Where the underscore is used
- Usernames and emails — john_smith, because spaces are not allowed.
- File names — report_final_v2.pdf.
- Programming — snake_case variable names like user_id, and private names in Python such as __init__.
- Markdown — text between underscores becomes italic.
- Fill-in-the-blank forms — Name: ________.
Don’t confuse it with the hyphen ( – ) or the dashes – and —, which sit in the middle of the line.
Underscore _ codes for web and code
Copy the exact code for HTML, CSS or JavaScript.
_ Underscore (low line)
‗ Double low line
_ Fullwidth low line
Frequently asked questions
Typing and using the underscore.
Where is the underscore on a keyboard?
It is on the same key as the minus sign, to the right of 0 in the top row. Hold Shift and press that key.
What is the Alt code for underscore?
Hold Alt and type 95 on the number pad.
What is the difference between an underscore and a hyphen?
A hyphen ( – ) sits in the middle of the line and joins words. An underscore ( _ ) sits on the baseline and is used where spaces are not allowed, such as usernames and file names.
What is the underscore called?
Its Unicode name is LOW LINE. It is also called understrike, low dash or underbar.
What is the HTML code for underscore?
Use _ or _. In normal HTML you can also just type _ directly.
Related symbols
More characters you can copy in one click.