Skip to content

Primary device attributes (DA1)

Category: device · Baseline: modern · Tags: ECMA-48 Standard, VT100 · Specification ↗

ESC [ c
DA1 (Primary Device Attributes) lets applications identify the terminal type and its capabilities. The query is ESC [ c or ESC [ 0 c. The terminal responds with ESC [ ? attributes c where attributes is a semicolon-separated list of capability codes. DA1 is one of the first sequences an application sends to discover what the terminal supports. The response identifies the terminal class (VT100, VT220, etc.) and optional capabilities. Modern terminals typically identify as VT220 or higher with various capability flags. Shell integration scripts and TUI frameworks use DA1 to enable or disable features based on terminal capabilities.
How this is testedautomated
Send \x1b[c (DA1), verify response contains ? and ends with c (e.g., \x1b[?62;...c).

The same probe runs against headless backends (via Termless) and real terminal apps (via a daemon launched in each terminal). This lets us distinguish parser correctness from rendering correctness.

Analysis2026-04-06

Supported by all 12 tested terminals — universal adoption. Part of the Modern TUI baseline.

Supported by 10 of 14 backends (71%)

Terminal Applications

TerminalVersionSupportNotes
iTerm23.6.9✓ yes
Ghostty1.3.1✓ yes
VS Code✓ yes
Warp✓ yes
Cursor✓ yes
Terminal.app✓ yes

Headless Backends

Parser correctness only — a means the parser accepts the sequence.

BackendVersionSupportNotes
vt100.js0.2.1✓ yesNo output stream — pure TypeScript emulator
vterm0.2.0✓ yes
Alacritty0.26.0~ partialHeadless mode has no output stream for DA1 responses
Kitty0.40.0~ partialHeadless mode has no output stream for DA1 responses
WezTerm0.1.0-fork.5~ partialHeadless mode has no output stream for DA1 responses
xterm.js5.5.0~ partialHeadless mode has no output stream for DA1 responses