On a phone, scroll inside the table to read every column. Replace the example roles and review triggers with your own.
| Page | Owner | Review trigger |
|---|---|---|
| Services | Business owner | When an offer changes |
| Contact | Website maintainer | After a contact detail changes |
| FAQ | Business owner | When a recurring question changes |
Decide whether you need a table
Use a table when readers compare related values across rows and columns. A schedule, size comparison, or content review plan can benefit from that structure. If the content is simply a sequence of instructions, a numbered list may be easier to read on a phone. Do not put a table around ordinary paragraphs just to arrange a page.
Before editing code, remove repeated wording and clarify long headings. Keep information that changes the buyer's decision. Hiding an important column on mobile or replacing the table with a screenshot can make the page look smaller while making the information harder to use.
Keep the relationships in the HTML
A caption gives the table a topic. Header cells identify the meaning of the data: the example uses column headers and a row header for each page. The W3C tables tutorial explains these relationships. More complex tables with grouped headings need additional consideration; this simple pattern is not a universal fix.
Here is the markup for the working example. Change the caption, rows, and IDs for your real content. If the page contains another table, give it a distinct caption ID so each region has the correct accessible name.
<div class="table-scroll" role="region"
aria-labelledby="review-caption" tabindex="0">
<table>
<caption id="review-caption">Example content review plan</caption>
<thead><tr>
<th scope="col">Page</th>
<th scope="col">Owner</th>
<th scope="col">Review trigger</th>
</tr></thead>
<tbody>
<tr><th scope="row">Services</th><td>Business owner</td><td>When an offer changes</td></tr>
<tr><th scope="row">Contact</th><td>Website maintainer</td><td>After a contact detail changes</td></tr>
<tr><th scope="row">FAQ</th><td>Business owner</td><td>When a recurring question changes</td></tr>
</tbody>
</table>
</div>Contain scrolling without shrinking the text
Place the overflow rule on the wrapper around the table. Keep normal text sizing and allow cell text to wrap. The example's minimum width is a starting point for this particular three-column table. Adjust it after reading your actual headings and longest entries; it is not a required width for every table.
.table-scroll { max-width: 100%; overflow-x: auto; }
.table-scroll table { width: 100%; min-width: 42rem; border-collapse: collapse; }
.table-scroll th, .table-scroll td { padding: .7rem; text-align: left; white-space: normal; }
.table-scroll:focus-visible { outline: 3px solid #2463eb; outline-offset: 3px; }Scope these rules to your table or resource page so an edit does not change a shopping cart, admin screen, or unrelated comparison. Check whether an existing parent uses a fixed width or a grid item needs min-width: 0. The mobile layout troubleshooting guide covers finding the wider element when the whole page still scrolls sideways.
The region has an accessible name and tabindex="0" so a keyboard user can reach its scroll area. Keep a visible focus indicator, avoid positive tabindex values, and test that focus can leave the region. Google’s CSS overflow guidance discusses keyboard access to scroll containers.
Test the information and interaction
Open a phone-width preview and read the first and last columns. Check a longer entry, enlarged text, and a desktop window. Scroll the table horizontally and confirm that its content remains available. Then move outside the table: the surrounding heading, navigation, and next action should fit the page width.
Use Tab to reach the named region, check horizontal scrolling with the keyboard, and continue to the next control. Where possible, check the table with a screen reader to hear whether headers provide useful context. A screenshot or an automated pass alone does not establish complete accessibility. The accessibility checklist covers other page elements.
Publish and assign future updates
Find the source file or template that generates the table. A change to generated HTML can disappear on the next build. Review the diff for unrelated edits, run the website's existing checks, and use its normal deployment workflow. Open the exact public URL afterward and repeat the table and keyboard checks.
Agree on who supplies changed values and who updates the page. Keep dates, availability, units, and row labels consistent with the business's actual information. If the table becomes too complex to navigate, consider a smaller set of focused tables or another presentation rather than adding more workarounds.
For the full DIY publishing workflow, see the BUILD • PUBLISH • OWN IT guide. For ongoing content and technical updates, review website management.
Need help with a table on your website?
Send the page URL, the columns that must stay available, and the phone-width problem you see. We can review the scope of the update.
Request website help