How do I know if my websites structure is laid out correctly?

Question

My page looks good visually, but I am not sure if its structure is laid out properly or if I used the right elements. How am I supposed to know if I've done things the "right" way?

Answer

Your site should have the correct semantic elements (header, main, footer, article, etc) in the order that they are intended to be read. This means that sometimes this isn't the order that makes styling the page the easiest. You must also ensure that all your heading levels are hit in the order. This means that you should not skip from an h1 to an h4, and so on.

You should always use native elements when possible (<button>, <input>, <select>, etc). If you can't, ensure you are following the ARIA design pattern for the role.

You can also use W3's Nu HTML Validator to check for proper nesting of elements, complete start/end tags and duplicate attributes.

Free Tools to Continue Learning

Accessible Web Company Logo

Accessible Web RAMP

Monitor your website and manage your progress towards WCAG conformance.

Accessible Web Company Logo

Accessible Web Academy

Career specific courses to help power up your accessibility knowledge.