Structuring code and navigation
Think of code hierarchy when structuring your content. Be sure screen readers and keyboard-only users can access interactive elements in a logical and predictable order via tabbing. Begin with the header, followed by the main navigation, then page navigation (from left to right, top to bottom), and end with the footer. Keyboard users should encounter an intentional experience that is comparable to the experience of mouse users.
Use semantic HTML
Use native HTML elements as much as you can. These elements have built-in accessibility benefits. They inform screen readers what they are and what they do, and standard interactive elements, such as a button, include keyboard functionality. Aside from making a page accessible, native HTML is easier to develop and maintain, better on mobile, and improves search engine optimization.
Use clear language
When adding content, consider cognitive disabilities, anyone whose native language isn’t the language your content is written in, and screen readers. When possible, avoid dashes, abbreviations, acronyms (at least the first time), and table layouts if a table is not needed. If abbreviating, use the native <abbr /> element with title attribute.
Designing accessible data tables
Always specify table headers with <th /> elements, and make sure they stand out. Utilize scope attributes if necessary to specify if they are headers for rows or columns. Utilize alternative text along with tables for visually impaired users. <caption /> is preferred, but <table /> summary works too.
Utilize ARIA roles and landmark roles
ARIA (Accessible Rich Internet Application) roles convey the intent or meaning of an element to assistive technology. This helps users navigate when they can’t see the layout and provides further context about different functionalities.
Landmark roles identify regions in a page, and act much like native HTML tags would when it comes to semantics. Signpost roles describe other information about a given element’s functionality on a page. These are especially helpful when building complex, custom interfaces or to reinforce semantics in native HTML elements.