HTML <th> Tag
Description
The <th> (table header) element in HTML is used to define a header cell in a table. Header cells are typically displayed as bold and centered by default, helping to distinguish them from regular table data cells (<td>). They provide semantic meaning to the table, indicating that the content of the cell serves as a header for a row, column, or group of rows/columns.
A <th> element can be placed inside a <tr> (table row) within the <thead>, <tbody>, or <tfoot> sections of a table. Its primary purpose is to improve both readability and accessibility, as header cells are used by screen readers and other assistive technologies to provide context for table data.
Visually, most browsers render <th> text in bold and center-aligned by default, although this can be customized using CSS. Semantically, <th> cells can describe the content of the column or row they head, making complex tables easier to understand and navigate.
Additionally, <th> can be used in combination with the scope attribute to explicitly define whether it is a header for a row, column, or group of rows/columns, further enhancing clarity for assistive technologies.
Properties
- Permitted Parents
- A <tr> element
- Content
- Block, inline and text
- Start/End Tags
- Start tag: optional, End tag: optional
Example
Attributes
Global Attributes
The <th> tag also supports the Global Attributes in HTML5
Event Attributes
The <th> tag also supports the Event Attributes in HTML5
Browser Support
The following information will show you the current browser support for the HTML <th> tag. Hover over a browser icon to see the version that first introduced support for this HTML tag.
This tag is supported by all modern browsers.
Desktop
Tablets & Mobile
Last updated by CSSPortal on: 26th December 2025
