In HTML, a table is used to organize and display data in a grid format of rows and columns.
<table>
: The container for the entire table.<tr>
: Defines a table row.<th>
: Defines a header cell, which is typically bold and centered.<td>
: Defines a standard data cell.Try it yourself
<caption>
: Adds a title to the table.<colspan>
: Allows a cell to span multiple columns.<rowspan>
: Allows a cell to span multiple rows.Try it yourself
Tables can be styled with CSS to improve their appearance.
Try it yourself