HTML - Forms and Tables Part 2

May 14, 2026 3:00pm UTC (Check your timezone)

Theory Workshop Lab

Instructors: Jess, Carmen, and Eda

Forms and Tables

Download iCal File

Before this session, please:

During this session, we’ll:

After this session, please:

Instructor notes

Working with Tables: What Are HTML Tables Used For, and What Should They Not Be Used For?

Today we add a new family of elements to our toolkit: HTML tables. They aren’t used as much as they used to be, but as a front-end developer you should still be comfortable with them. They were one of the earliest ways developers had for displaying data in a browser, going back to the 1990s.

Table: an HTML element used to display tabular data, meaning data that naturally fits into rows and columns. Think of a spreadsheet, a class schedule, sports standings, a pricing comparison, or a list of facts about something.

There are a handful of elements that work together inside a table, and they follow a simple hierarchy:

Structural sections (children of <table>):

Inside each of those sections:

Inside each row:

Here is the simplest possible table that uses all of these:

 1<table>
 2  <thead>
 3    <tr>
 4      <th>The title of this table</th>
 5    </tr>
 6  </thead>
 7  <tbody>
 8    <tr>
 9      <th>First Row</th>
10      <td>First Data Cell</td>
11    </tr>
12    <tr>
13      <th>Second Row</th>
14      <td>Second Data Cell</td>
15    </tr>
16  </tbody>
17  <tfoot>
18    <tr>
19      <th>The footer of this table, which might contain dates or sources.</th>
20    </tr>
21  </tfoot>
22</table>

A few things to notice from that example:

What tables should NOT be used for:

Recap: if your data has rows and columns, use a table. If it doesn’t, don’t.

Questions: