Global Attributes

HTML tabindex attribute

Controls focusability and sequential focus order. 0 follows natural document order; -1 allows programmatic focus without ordinary tab navigation; positive values usually harm logical keyboard navigation. Applicability: global HTML attribute, subject to element-specific restrictions and browser support.

Formal Syntax & Structure

html syntaxhtml
tabindex="-1"

Parameters & Attributes

NameTypeDescription
tabindexintegerControls focusability and sequential focus order. 0 follows natural document order; -1 allows programmatic focus without ordinary tab navigation; positive values usually harm logical keyboard navigation.

Working Example

Example Snippethtml
<h2 tabindex="-1" id="results">Search results</h2>
HTML Reference