Skip to main content
ansicode

SGR 90–97 — Bright foreground color

Bright variants of the 8 basic foreground colors (aixterm/xterm extension).

Byte forms

Every common string-literal form so you can paste-and-search either direction.

\\x1b[\x1b[91m (bright red, 90–97)
\\033[\033[91m
\\e[\e[91m
ESC [ESC [ 9 1 m
hex1b 5b 39 31 6d

Description

Non-standard but ubiquitously supported aixterm extension that exposes the upper 8 of the original 16-color palette as their own SGR parameters. 90 bright black (gray), 91 bright red, ..., 97 bright white. Equivalent to combining `\x1b[1m` + a basic color on terminals that use bold-as-bright; on modern terminals the two paths render differently and bright codes are preferred.

Spec citation: aixterm color extension (xterm-ctlseqs)

Examples

bash
for c in 90 91 92 93 94 95 96 97; do printf "\033[${c}m■\033[0m"; done; echo
python
for c in range(90, 98): print(f'\x1b[{c}m■\x1b[0m', end='')
go
for c := 90; c <= 97; c++ { fmt.Printf("\x1b[%dm■\x1b[0m", c) }
javascript
for (let c = 90; c <= 97; c++) process.stdout.write(`\x1b[${c}m■\x1b[0m`)
c
for (int c = 90; c <= 97; c++) printf("\x1b[%dm■\x1b[0m", c);

Terminal support

xterm
yes
Linux console (fbcon)
yes
macOS Terminal.app
yes
iTerm2
yes
Windows Terminal
yes
cmd.exe / ConPTY
yes
kitty
yes
alacritty
yes
WezTerm
yes
Ghostty
yes
GNOME Terminal
yes
Konsole
yes
tmux
no
GNU screen
no

Related sequences

In the family cookbook

SGR cookbook · 2. 16-color basic — `\x1b[31m` and friends