EEnterUI
DocsComponentsThemesDonation
Get Started
      • TagsInput
      • FileUpload
      • OTPInput
      • TimeInput
EnterUIDocsInputsEditing and UploadToken and File InputsOTPInput
InputsUpdated 6 May 2026

OTPInput

Verification code input with paste and mobile numeric support.

OTPInput is built for account verification, two-factor flows, and short PIN entry.

#Default usage

Verification code

Digits move across fixed slots and support full-code paste.

Code
<OTPInput defaultValue="4320" length={6} />

#Import

Code
import { OTPInput, PinInput } from "@froggdesign/enter-ui-react";

#States

OTP states

Use invalid only after validation fails.

#Accessibility

Each slot is a named input, uses numeric input mode, and the first slot advertises one-time-code autocomplete. Paste accepts a full code and normalizes it to digits.

#API

  • length controls slot count.
  • value, defaultValue, and onValueChange control the code.
  • disabled and invalid map to aria state and data attributes.
  • PinInput is an alias for PIN wording.

#Styling

Every exported component accepts className when it renders an element. EnterUI styles use .eui-* classes and --eui-* variables mapped from FroggDesign theme tokens.

PreviousFileUpload
NextTimeInput

On this page

  1. Default usage
  2. Import
  3. States
  4. Accessibility
  5. API
  6. Styling