Home
← All questions

Semantic HTML and web accessibility basics | Web Fundamentals

MediumPremiumWeb Fundamentals

Asked at Google · Microsoft · Apple

Web Fundamentals interview practice: Use semantic elements and ARIA correctly

Answer

Semantic HTML gives meaning to structure (<nav>, <main>, <article>, <button>) so assistive tech and SEO understand the page without extra ARIA.

Accessibility pillars (POUR):

  • Perceivable — alt text, contrast, captions
  • Operable — keyboard nav, focus visible, no seizure triggers
  • Understandable — labels, error messages, consistent nav
  • Robust — valid HTML, ARIA only when native semantics insufficient

ARIA rules: "No ARIA is better than bad ARIA." Don't replace <button> with <div role="button"> unless necessary.

Premium question

Unlock the full model answer with Mentoxis Premium.

Unlock with Premium