guilhermerodz/input-otp

One time passcode Input. Accessible & unstyled.

View on GitHub ↗Jump to charts ↓Open shareable report →

guilhermerodz/input-otp has 3k+ stars and 90+ forks on GitHub, is written in JavaScript, and was last pushed on Sep 10, 2026. Data as of . Signed-in members get hourly updates — create a free account.

Summary Information

Updated 1 hour ago
Added to GitGenius on September 21st, 2026
Created on February 13th, 2024
Open Issues & Pull Requests: 14 (+0)
GitHub issues: Enabled
Number of forks: 93
Total Stargazers: 3,268 (+0)
Total Subscribers: 3 (+0)

Repository Insights (GitGenius)

Median issue/PR response: 0.0 hours
Mean response time: 20.4 days
90th percentile: 32.7 days
Tracked items: 37

Maintainer activity

1 person did triage or write work on this repository in the last 12 months.

Counts unlabeled, assigned, unassigned, milestoned, demilestoned, locked, unlocked over the last 12 months. These are issue and pull request events that require triage or write permission. Commits and code review are not counted. labeled and renamed are excluded because GitHub issue forms record the issue author as the actor. Figures from October 18, 2026. This count is not comparable across projects: each project's automation decides which of these events a person emits. How this is counted.

Charts & Analytics

Fetching additional details & charts...

Issue Activity (beta)

Open issues: 5
New in 7 days: 0
Closed in 7 days: 0
Avg open age: 363 days
Stale 30+ days: 3
Stale 90+ days: 1

Recent activity

Opened in 7 days: 0
Closed in 7 days: 0
Comments in 7 days: 0
Events in 7 days: 0

Top labels

  • bug (23)
  • help wanted (5)
  • invalid (5)
  • urgent (4)
  • good first issue (2)
  • documentation (1)
  • enhancement (1)
  • wontfix (1)

Most active issues this week

Sign in to see which issues are moving.
Sign in

Detailed Description

input-otp is a React component for building one-time-password inputs that is accessible and unstyled.

The problem it solves is that HTML has no native OTP control, so developers typically build one from six separate inputs wired together with keydown handlers. This approach breaks browser features like SMS autofill, screen reader support, partial paste, undo, and standard keyboard bindings. input-otp instead renders a single invisible text input and provides the state needed to render any UI on top of it. Because there is still a real text field underneath, all browser functionality continues to work: SMS autofill via the autocomplete attribute, proper screen reader announcements with one control and one caret, standard keyboard shortcuts like select-all and undo, partial paste into the middle of a code, and correct form semantics with a single name and FormData entry.

The tool suits any project building two-factor or multi-factor authentication flows where you want full control over the visual presentation while maintaining accessibility and browser compatibility. It has zero dependencies, works with React versions from 16.8 onward, and is small enough to include without concern. The README notes that shadcn/ui wraps this library with pre-composed parts if you prefer a component-based API over the render prop pattern.

The project maintains active engagement with its ecosystem, as evidenced by sponsorship from authentication and infrastructure providers. Development appears focused on handling edge cases comprehensively, with dedicated documentation covering unusual scenarios that arise when a single invisible input must behave like multiple boxes. The API surface is deliberately minimal, consisting of five props, which suggests a philosophy of solving a specific problem well rather than expanding scope.