Keyboard keys · guide

Where is the Backslash key?

Right end of the top letter row, above Enter and right of ]. Shift on it types the pipe |. UK (ISO) keyboards move it to the left of Z, next to the left Shift.

\|

At a glance
Full-size keyboard
Right end of the top letter row, above Enter and right of ].
Laptop
Above Enter on US laptops; next to the left Shift on UK laptops.
Mac
Right of ] above return on US Macs.

Backslash key location

Backslash key on a full-size keyboard Esc F1 F2 F3 F4 F5 F6 F7 F8 F9 F10 F11 F12 SysRq PrtSc Lock Scroll Break Pause ~ ` 1 2 3 4 5 6 7 8 9 0 _ - + = Backspace Insert Home Up Page Lock Num / * - Tab Q W E R T Y U I O P { [ } ] | \ Delete End Down Page Home 7 ↑ 8 PgUp 9 + Caps Lock A S D F G H J K L : ; " ' Enter ← 4 5 → 6 Shift Z X C V B N M < , > . ? / Shift ↑ End 1 ↓ 2 PgDn 3 Enter Ctrl Win ⊞ Alt Gr Alt Win ⊞ Menu ≡ Ctrl ← ↓ → Ins 0 Del .
Full-size Windows keyboard (ANSI 104-key) Backslash / pipe

Right end of the top letter row, above Enter and right of ]. Shift on it types the pipe |. UK (ISO) keyboards move it to the left of Z, next to the left Shift.

What the Backslash key does

The backslash separates folders in Windows paths (C:\Users), escapes characters in programming (\n for newline), and starts commands in LaTeX. Shift+\ types the vertical bar |, the pipe used to chain commands in terminals.

On a Mac

Same key above return. Mac paths use forward slashes, so backslash is mainly for code and escaping.

On a laptop

Its position depends on the layout more than the laptop: US above Enter, UK/ISO next to left Shift.

Shortcuts that use the Backslash key

ShortcutWhat it does
\Backslash
Shift+\Pipe |
Alt+92Backslash via Alt code
\\ in codeA literal backslash
Alt Gr+- (some European layouts)Backslash

If the Backslash key is missing or not working

If the key types # or ~, the wrong layout is active (UK vs US). Test the key below; it reports as Backslash on ANSI layouts and IntlBackslash on ISO layouts.

Test it here: click the tester, press the key, and it should light up green. A red key is stuck; a key that never lights up is dead or intercepted by the system. The full keyboard tester has the press log and more detail.

0 keys tested

Click the tester, then press any key. Browser shortcuts are blocked while it has focus.

Keyboard tester (windows) Esc F1 F2 F3 F4 F5 F6 F7 F8 F9 F10 F11 F12 SysRq PrtSc Lock Scroll Break Pause ~ ` 1 2 3 4 5 6 7 8 9 0 _ - + = Backspace Insert Home Up Page Lock Num / * - Tab Q W E R T Y U I O P { [ } ] | \ Delete End Down Page Home 7 ↑ 8 PgUp 9 + Caps Lock A S D F G H J K L : ; " ' Enter ← 4 5 → 6 Shift Z X C V B N M < , > . ? / Shift ↑ End 1 ↓ 2 PgDn 3 Enter Ctrl Win ⊞ Alt Gr Alt Win ⊞ Menu ≡ Ctrl ← ↓ → Ins 0 Del .
Full-size Windows keyboard (ANSI 104-key) Hover or tap a key
Last key

—

key
—
code
—
keyCode
—
Held right now

none

Max at once: 0 (rollover)

Stuck keys

None detected. A key held for more than 2 seconds is flagged.

Frequently asked questions

Where is the backslash on a UK keyboard? +

Next to the left Shift key, below Caps Lock. On US keyboards it is above Enter.

How do I type a backslash on a laptop without the key? +

Hold Alt and type 92 on the numpad, or use Win+. and search "backslash". On many European layouts Alt Gr+- or Alt Gr+ß types it.

What is the difference between \ and /? +

The backslash leans left and is used in Windows paths and code escapes; the forward slash leans right and is used in URLs, fractions and Mac/Linux paths.

Every key

Where is the… key?

Keyboard keys hub →
✓ Copied to clipboard