One-time-code / PIN entry across separate digit cells. Typing auto-advances, Backspace steps back, arrows navigate, and pasting a code distributes its digits across the cells.
length sets the number of cells (default 4).
Two sizes — l (default) and
xl.
verification codes, 2FA, and short PIN entry.
Form-associated — the host submits the joined value and fires a
complete event when every cell is filled. For
general text, use Input.
length to the real code length so paste fills cleanly.help-text.state="negative" with a message when a code is wrong.role="group" labelled by the field label and described by the help text.autocomplete="one-time-code" so OS code suggestions work.inputmode="numeric" brings up the number pad on mobile.required sets valueMissing until all cells are filled; emits input, change, and complete.