Neova高级 SEO 平台

select 元素没有可访问名称

在 Neova 中 直接在抓取过程中运行,无需任何设置。

规则最近审核:2026年10月17日 · 指南更新:2026年7月7日

WCAG 4.1.2 要求每个表单控件都有名称。没有名称的 select,不会告诉使用屏幕阅读器的用户他们在选择什么。

您可以做什么

添加一个通过 for 和 id 与该 select 关联的 label 元素,或为该 select 设置 aria-label。

Neova 为何标记

  • 没有名称的下拉框只会被读出类型,用户不知道自己在选什么。
  • WCAG 4.1.2(A 级)要求每个表单控件都有名称。
  • 填写表单的 AI 智能体也依靠同一个名称来选择选项。

来源

完整指南

这一部分目前只有英文版。

Select element must have an accessible name: how to fix it
TL;DR

A <select> dropdown needs a real label. The first <option> reading "Choose one" is not a name, so tie the control to a <label> and screen readers announce its purpose.

This check flags a <select> that has no accessible name, meaning nothing tells assistive tech what the dropdown is for. A screen reader lands on it and announces "combo box" with no context, so the user is choosing blind between options like "US" and "CA" without knowing they are picking a country. Dropdowns gate a lot of high-intent flows, shipping, filters, plan selection, and an unnamed one quietly kills completion for anyone not using a mouse.

Why a Placeholder Option Is Not a Name

This is the single most common misunderstanding behind the failure, so it is worth being blunt about. The first <option> in a select, the "Select a country" line, is a value inside the list, not a label for the control. Sighted users read it as a prompt because it happens to be showing when the menu is collapsed, and developers assume screen readers treat it the same way. They do not. The accessible name is computed from labels and ARIA attributes on the <select> itself, and an option's text never enters that calculation. So a dropdown whose only "label" is a placeholder option announces with no name at all, or with the placeholder text read as the current value rather than as the field's purpose. The moment the user picks a real option, even that prompt disappears, and there is nothing left to tell them what the field was. That is why the fix has to live on the control, through a <label> or an ARIA attribute, and not inside the option list.

A Real Failure, and the Fix

The usual culprit leans on a placeholder option and visual proximity instead of a real association:

Country
<select name="country">
  <option value="">Select a country</option>
  <option value="us">United States</option>
  <option value="ca">Canada</option>
</select>

The word "Country" is just floating text; it is not connected to the control. Bind them with a matching for and id:

<label for="country">Country</label>
<select id="country" name="country">
  <option value="">Select a country</option>
  <option value="us">United States</option>
  <option value="ca">Canada</option>
</select>

Now the control is announced as "Country, combo box," and the placeholder option stays exactly where it belongs, as a prompt inside the list.

Ways to Name a Select, Ranked

Method When to Use It Visible?
<label for> Default choice, visible text present Yes
Wrapping <label> Label and control kept together in markup Yes
aria-labelledby Name lives in an existing element elsewhere Yes
aria-label Compact UI with no room for visible text No
Placeholder <option> Never, as a name; it is not a label —

How to Detect It

  1. axe DevTools: run the extension; "Select element must have an accessible name" lists each unnamed dropdown with a link straight to the node.
  2. Lighthouse: run the Accessibility audit in Chrome DevTools and check the "Names and labels" group, where unlabeled selects are reported.
  3. WAVE: load WAVE and look for the red "Missing form label" marker sitting on the select control.
  4. Manual check: click the dropdown and confirm a <label> with a matching for exists, or that an aria-label/aria-labelledby is present in the markup.

How to Fix It

Reach for a native <label for> first, since it names the control and enlarges the click target at the same time. If the design has no visible label, use aria-label with clear, purpose-first text. When the name already exists in another element, such as a section heading, reference it with aria-labelledby. Do not lean on a placeholder <option>, on title, or on nearby text that is not programmatically linked. The same accessible-name rule applies to text inputs in form input elements must have labels and to ARIA-role fields in ARIA input fields must have an accessible name.

Watch out for the custom-dropdown trap. A lot of design systems hide the native <select> and paint a styled widget on top of it out of <div> and <ul> elements. If you go that route, the ARIA combobox pattern is now your responsibility, roles, states, keyboard handling, and a name on the trigger, and it is far easier to get wrong than a native control. Unless you have a strong reason, keep the real <select> and style it; you inherit correct keyboard support and naming for free, and this check becomes a one-line fix. Whichever path you take, always verify the outcome with a screen reader rather than trusting the visual, because a dropdown can look perfectly labeled on screen while announcing as an anonymous combo box.

Frequently Asked Questions

Does the First <option> Count as a Label?

No. A placeholder option like "Select a country" is content inside the list, not an accessible name for the control. Screen readers do not treat it as the field's name, so the check still fails.

Is a Visible Label Always Required?

A visible label is best for everyone, but the check passes with any accessible name, including aria-label. That said, a name that no sighted user can see is a usability trade-off, so prefer visible text where the layout allows.

Can I Name a Multi-Select the Same Way?

Yes. A <select multiple> follows the exact same rules; associate it with a <label> or an ARIA attribute and it will be announced correctly.

Which WCAG Criterion Is This?

It supports 4.1.2 Name, Role, Value and 3.3.2 Labels or Instructions, both Level A. Together they require the control to expose a programmatic name that describes its purpose.

Need a full technical audit?

Neova runs deep crawls that catch issues like this across your whole site.

在您自己的网站上找到它

Neova 在每次抓取时都会运行此检查项和其他所有检查项,然后把修复方法写成工单交给您的团队。

  • 适用于 Mac、Windows 和 Linux 的桌面应用
  • 全部 696 项检查,每项都附来源
  • Search Console 和 Analytics 4,以只读方式连接
  • 工单发送到 Jira、Linear 和 Asana

下载 Neova Desktop Free 套餐,或免费试用 Solo 14 天,无需银行卡。

全部无障碍检查 · 指南 · 检查项库

作者:Neova Labs · 返回检查项库