How to Type Square Brackets []
Keyboard shortcuts for Windows, Mac, Chromebook, iPhone & Android. Type or copy all bracket types instantly.
Brackets & Parentheses to Copy
Click any bracket to copy instantly
Square brackets [ ] are essential in programming, mathematics, linguistics, and everyday writing. They're used for arrays in code, citations in academic writing, phonetic transcriptions, and optional elements in documentation.
On US and UK keyboards, square brackets have dedicated keys. But on German (QWERTZ) and many international keyboards, they require special key combinations — AltGr+8 for [ and AltGr+9 for ] — which can be frustrating to discover.
This guide covers square brackets and all related bracket types across every major platform. Whether you're writing code, editing an academic paper, or formatting text, you'll find the right method for your device below. All bracket characters on this page are Unicode text that works everywhere.
Typing Square Brackets [ ] on Any Layout
Square brackets [ ] have dedicated keys just to the right of the P on US and UK keyboards, so you type them with no modifier at all. Their Unicode code points are U+005B for the opening bracket and U+005D for the closing one, written in HTML as [ and ] (or [ and ]). On Windows a numeric keypad offers a backup: hold Alt and type 91 for [ or 93 for ]. The frustration begins on German QWERTZ layouts, where the brackets vanish from their obvious spot and hide behind AltGr — AltGr+8 gives [ and AltGr+9 gives ].
On a Mac the US and UK layouts keep the brackets on their own keys near Return, while the German Mac layout places them at Option+5 for [ and Option+6 for ]. Mobile keyboards store them on a secondary symbols page, often one long-press away from the parentheses. Programmers lean on square brackets constantly for array indexing and list literals, and outside code they enclose editorial insertions in quotations, mark citations in academic writing, and wrap phonetic transcriptions in linguistics.
Square Brackets FAQ
The alt code for the left square bracket [ is Alt+91. For the right square bracket ] it's Alt+93. Hold Alt, type the number on the numeric keypad, then release. For curly brackets: Alt+123 for { and Alt+125 for }. Num Lock must be enabled.
On a German QWERTZ keyboard, press AltGr+8 for [ and AltGr+9 for ]. AltGr is the right Alt key. For curly brackets, press AltGr+7 for { and AltGr+0 for }. On German Mac keyboards, use Option+5 for [ and Option+6 for ].
Square brackets [] are used for arrays in programming, optional items in documentation, and editorial comments in quotes. Curly brackets {} (braces) define code blocks, objects, and sets. Parentheses () group expressions, contain supplementary information, and define function parameters. In math, they follow the nesting order: {[()]}.
On US/UK Mac keyboards, press the [ and ] keys directly (to the right of P). On German Mac keyboards: press Option+5 for [ and Option+6 for ]. For curly brackets: Option+8 for { and Option+9 for }.
Square brackets are fundamental in programming: array indexing (arr[0]), list definitions in Python ([1, 2, 3]), object property access in JavaScript (obj['key']), regex character classes ([a-z]), and JSON arrays. They're one of the most frequently typed characters in code.
Yes! Unicode offers many decorative bracket styles that work on all platforms: 【title】for emphasis, ⟦text⟧ for mathematical notation, and ⟨angle brackets⟩ for linguistic or technical writing. All bracket characters on this page are Unicode text that displays correctly everywhere.