# Native HTML Choice Inputs: The Four Patterns That Fix Forms Without JavaScript

If your site audit keeps flagging form accessibility issues, there is a good chance the root cause is not a missing ARIA attribute. It is that your choice inputs were rebuilt in JavaScript when the browser already shipped them for free.

I reached this conclusion the slow way. Over one stretch this year I reviewed around fifty web forms across a dozen teams: signup flows, checkout pages, survey builders, internal admin tools. The same anti-pattern surfaced in nearly all of them. A form needed the user to select one option, or select several, and the codebase answered with script. A dropdown component pulled from a UI library. A custom multi-select wired up with state and event handlers. A toggle group built by hand. Collectively, thousands of lines to do a job native HTML has handled since before these projects started.

The overwhelming majority reached for JavaScript. A handful used the native elements. And almost none of the scripted versions did anything the platform could not already do.

Here are the four native HTML choice inputs, what each is for, and why the native element should be your default before any component library enters the conversation.

## Radio buttons: when the answer is exactly one option

A radio group is the correct tool whenever the choices are mutually exclusive: shipping speed, payment method, a visible yes/no question. The single most common bug I flagged was the `name` attribute. Every option in a radio group must share the same `name`, because that shared name is what makes the options mutually exclusive. Miss it, and users can select every option at once, which is both a UX failure and a data-integrity problem on the server.

```html
<fieldset>
  <legend>Shipping speed</legend>
  <label><input type="radio" name="shipping" value="standard" checked> Standard</label>
  <label><input type="radio" name="shipping" value="express"> Express</label>
  <label><input type="radio" name="shipping" value="overnight"> Overnight</label>
</fieldset>
```

Wrap the group in a `<fieldset>` with a `<legend>`, associate every input with a `<label>`, and set one sensible default with `checked`. The `<legend>` is what assistive technology announces as the question for the group. Skipping it is a silent accessibility failure that no visual QA pass will catch, but a screen-reader test or an automated audit will.

## Checkboxes: zero, one, or many

When a user can select more than one option, or none at all, checkboxes are the answer. Each checkbox is independent, so a shared `name` is not required for them to function. Giving related boxes the same name is still worth doing, because it makes the submitted data far cleaner to read and validate on the server.

```html
<fieldset>
  <legend>Notifications</legend>
  <label><input type="checkbox" name="notify" value="email"> Email</label>
  <label><input type="checkbox" name="notify" value="sms"> SMS</label>
  <label><input type="checkbox" name="notify" value="push"> Push</label>
</fieldset>
```

The lone standalone checkbox has its own classic role: the terms-and-conditions agreement, where the only meaningful states are checked and unchecked.

## The `<details>` disclosure: a dropdown with no script at all

This is the pattern people forget exists. The `<details>` and `<summary>` elements give you an expandable, collapsible section that the browser opens and closes on its own. No click handler, no state variable, no library.

```html
<details>
  <summary>Choose your plan</summary>
  <label><input type="radio" name="plan" value="free" checked> Free</label>
  <label><input type="radio" name="plan" value="pro"> Pro</label>
  <label><input type="radio" name="plan" value="team"> Team</label>
</details>
```

It is a disclosure widget, not a form control, so it will not post a value on its own. The inputs inside it do that. Its strength is collapsing long option lists, FAQ sections, and progressive-disclosure interfaces without any JavaScript, with keyboard support and open/close behavior already handled by the browser. For the full markup breakdown, see our [multi-choice HTML guide](https://www.siteauditlint.com/blog/multi-choice-html-guide).

## `<select multiple>`: the native multi-select list

When you genuinely need a compact multi-select rather than a wall of checkboxes, `<select multiple>` is the native option. Users hold Ctrl or Cmd to pick several entries.

```html
<label for="skills">Skills</label>
<select id="skills" name="skills" multiple size="4">
  <option value="html">HTML</option>
  <option value="css">CSS</option>
  <option value="js">JavaScript</option>
</select>
```

Be honest about the tradeoff. The Ctrl-click interaction is unintuitive for non-technical users and awkward on touchscreens. For short lists on public-facing forms, a group of checkboxes almost always beats it on usability. Reserve `<select multiple>` for dense, admin-facing interfaces where space is tight and users are comfortable with the interaction.

## A quick decision guide

| You need | Use |
| --- | --- |
| One answer from a short, visible set | Radio buttons |
| Many answers, or none | Checkboxes |
| Options hidden until requested | `<details>` |
| Compact multi-select, expert users | `<select multiple>` |

## Why this matters for site health and technical SEO

The discipline under all four patterns is identical: label every input, group related controls, and lean on the native element before reaching for script. The browser has already solved focus management, keyboard navigation, and accessibility for these controls. Rebuilding them in JavaScript tends to reintroduce bugs the platform retired years ago, and those bugs show up as real crawl and accessibility signals: inputs with no associated label, form controls a crawler cannot parse, interactive elements that fail keyboard testing. When a control only exists after a script runs, you are now in [JavaScript SEO and rendering](https://www.siteauditlint.com/academy/javascript-seo/rendering) territory, where whether a crawler sees the control at all depends on how and when it renders. Native markup is lighter, more resilient, and easier for both assistive technology and automated crawlers to understand. Pairing it with a proper [color contrast check](https://www.siteauditlint.com/color-contrast-checker) covers two of the most common accessibility failures at once.

That is the real takeaway from fifty forms. The problem was almost never that the native elements could not do the job. It was that nobody checked whether they could. Most reached for JavaScript. Few needed it.

If you want to find these issues at scale, run a [full site audit](https://www.siteauditlint.com/site-audit) and watch your [site health score](https://www.siteauditlint.com/features/site-health-score) react as you replace scripted controls with native markup.

---

*Written by* [*Remar Barquilla*](https://www.siteauditlint.com/about/remar-barquilla)*, founder of SiteAuditLint, writing on crawling, site health, and AI search visibility from the Philippines.*
