Pure Custom Select

Zero-dependency select web component. Native on mobile, keyboard-accessible, themeable. Try it on touch devices too.

Basic

Single choice with a placeholder.

No selection

Pre-selected

selected on an option sets the initial value.

No selection

Multiple

multiple — value becomes an array.

No selection

Searchable

searchable — built-in local filter with highlight.

No selection

Async search

onsearch(query) returns matching values (simulated 400ms latency).

No selection

Remote search

search-mode="remote": results come entirely from the server, including options that were never declared.

No selection

Grouped

<optgroup> renders section headers.

No selection

Disabled states

Disabled options and a fully disabled control.

No selection

Customized

Restyled purely via CSS variables — no JS, no overrides of internals.

#fancy {
  --cs-bg: linear-gradient(135deg, #6d28d9, #db2777);
  --cs-text: #fff;
  --cs-border: rgba(255,255,255,.25);
  --cs-border-radius: 14px;
}

Form integration

Works as a native form field via ElementInternals. Submit reads from FormData.

FormData will appear here…