Web
Web accessibility basics every team should ship
Web accessibility basics that cover most real-world needs: semantic HTML, keyboard navigation, contrast ratios, and ARIA, built in from day one.
TL;DR
A handful of fundamentals covers most accessibility needs. Build them in from day one and the incremental cost is near zero.

Accessibility gets treated as a specialist compliance topic, which causes teams to do nothing. A small set of web accessibility basics covers most real-world needs, costs almost nothing to build in from the start, and improves the product for every user. This is the baseline, in priority order.
Start with semantic HTML
The single highest-impact accessibility decision is using the right HTML element for the job. A <button> is focusable, keyboard-operable, and announced correctly by screen readers without any extra work. A <div> with a click handler is none of those things.
- Use
<button>for actions,<a>for navigation, never a styled<div> - Use headings (
<h1>to<h6>) in order to convey document structure - Use
<nav>,<main>,<header>, and<footer>landmarks - Tie real
<label>elements to their inputs
Get this right and most accessibility problems are solved before a single line of ARIA is written.
Make everything keyboard-operable
Many users navigate entirely by keyboard. Tab through the entire app and verify two things: every interactive element is reachable and activatable, and focus is always visible. A visible focus ring is not optional. Never remove the outline without replacing it with something equally clear.
Watch for keyboard traps (focus that gets stuck in a modal), custom dropdowns that ignore arrow keys, and click handlers placed on non-focusable elements.
Contrast and text sizing
Low-contrast text is the most common accessibility failure and fixing it is trivial. Aim for at least 4.5:1 contrast ratio for body text and 3:1 for large text. Never use color alone to convey meaning. An error state needs an icon or text label, not just a red border.
Let users zoom and resize text without breaking the layout. Never disable pinch-to-zoom on mobile.
Images and dynamic content
- Give informative images meaningful
alttext. Give decorative imagesalt=""so screen readers skip them. - Announce dynamic updates (toasts, live validation) with an
aria-liveregion so screen reader users hear the changes. - Ensure modals trap focus on open and return focus to the trigger on close.
Use ARIA sparingly
ARIA lets you patch accessibility onto custom widgets. The first rule of ARIA: don't use it if native HTML does the job. Wrong ARIA is worse than none. An incorrect role actively misleads assistive technology. Reserve ARIA for genuinely custom components (tabs, comboboxes, custom dialogs) and follow the established patterns rather than improvising.
Bake it into the workflow
Accessibility fails when it lives only in a pre-launch audit. Three cheap practices keep it healthy:
- Run an automated linter (axe, eslint-plugin-jsx-a11y) in CI to catch obvious regressions
- Tab through new features before merging
- Test occasionally with a real screen reader (VoiceOver on macOS, NVDA on Windows)
Automated tools catch roughly half of issues. The manual checks cover the rest, and neither takes long once the habit is formed.
If you need an existing product audited against WCAG or want accessibility built into a new build from the start, let's talk.
Frequently asked questions
What is the minimum contrast ratio for web accessibility?
WCAG requires a 4.5:1 contrast ratio for normal body text and 3:1 for large text (18pt or 14pt bold). Most design tools have built-in contrast checkers.
When should you use ARIA in HTML?
Use ARIA only when native HTML cannot express the semantics you need. Custom widgets like tabs, comboboxes, or dialogs are valid candidates. A wrong ARIA attribute actively misleads screen readers, so it is better to use none than to guess.
How do you test website accessibility?
Start with an automated linter like axe in CI to catch obvious failures. Then tab through new features manually to verify keyboard access and focus visibility. Periodically test with a real screen reader such as VoiceOver or NVDA.
Does semantic HTML improve accessibility?
Yes, significantly. Native HTML elements like button, a, nav, and label carry built-in keyboard behavior and screen reader announcements. Using them correctly solves the majority of accessibility issues before any ARIA is needed.
How Pykero can help
Services related to this article.
Building something like this?
Pykero Agency designs and ships production web, mobile, SaaS, and AI products.
Talk to us


