Always use a label
Adam Silver
59224

Thanks for writing this article!

For the web to continue thriving, we have to commit ourselves to creating an open and inviting environment for all of our users. Articles like this help foster that environment.

However, I do have one critique: this article implies that providing a label that is visible on the page is the only acceptable approach to providing a label for inputs.

However, this isn’t necessarily true: you can have a label element that is both invisible (to support a minimalist aesthetic or to reduce confusion from too much visual clutter) and accessible to screen readers. The accessibility resource website, WebAIM, actually supports this technique, including a specific example where the use of visible labels would actually make a set of input fields more confusing.

And, as screen reader support continues to grow, aria-label (rather than a label element) will likely become the primary method for providing a label to an input that does not require an actual visual label. Both the WCAG Working Group and MDN highlight this approach.

Ultimately, I’m not writing this to take a potshot at your article; I’m writing this because I think it’s important to stress the options and flexibility available to a web developer when creating accessible websites.

Too often accessibility is written off as an overly constricting set of standards when, in reality, it’s just like anything else when it comes to web development: rife with a number of approaches and opportunities that can all lead to a more open, inclusive web.