# mui-one-time-password-input

> A One-Time Password input designed for the React library MUI

Latest version **7.0.0** (published 2026-04-26) · MIT license · 0 weekly downloads

## Install

```sh
npm install mui-one-time-password-input
pnpm add mui-one-time-password-input
yarn add mui-one-time-password-input
bun add mui-one-time-password-input
```

## Health

**Score 60/100 (C)** — status: stable.

Positive: has types; esm support; no vulnerabilities; high quality score.

Warnings: low downloads.

## Facts

| | |
|---|---|
| Version | 7.0.0 |
| Published | 2026-04-26 |
| First published | 2022-09-06 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | ESM + CommonJS |
| Dependencies | 0 |
| Unpacked size | 10.5 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 151 |
| Author | Victor de la Fouchardiere |
| Maintainers | viclafouch |
| Keywords | react, typescript, input, mui, javascript, material, otp, form, password |

## Links

- npm: https://www.npmjs.com/package/mui-one-time-password-input
- Repository: https://github.com/viclafouch/mui-otp-input
- Homepage: https://viclafouch.github.io/mui-otp-input
- Issues: https://github.com/viclafouch/mui-otp-input/issues
- npm.io page: https://npm.io/package/mui-one-time-password-input

## Alternatives

- [mobx-react](https://npm.io/package/mobx-react.md) — 2.8M weekly downloads
- [rc-tree](https://npm.io/package/rc-tree.md) — 2.6M weekly downloads
- [@react-oauth/google](https://npm.io/package/@react-oauth/google.md) — 1.3M weekly downloads
- [@wagmi/connectors](https://npm.io/package/@wagmi/connectors.md) — 877.0K weekly downloads
- [vee-validate](https://npm.io/package/vee-validate.md) — 836.4K weekly downloads

## Recent versions

- 7.0.0 (latest) — 2026-04-26
- 2.0.1-alpha.1 (alpha) — 2023-10-20
- 6.0.0 — 2026-03-30
- 5.0.0 — 2025-04-13
- 4.0.1 — 2025-03-07
- 4.0.0 — 2025-03-07
- 3.0.2 — 2024-12-16
- 3.0.1 — 2024-11-10
- 3.0.0 — 2024-11-10
- 2.0.3 — 2024-07-06
- 2.0.2 — 2024-02-13
- 2.0.1 — 2023-10-20
- 2.0.1-alpha.0 — 2023-10-20
- 2.0.0 — 2023-08-04
- 1.2.5 — 2023-07-31
- … 13 more at https://npm.io/package/mui-one-time-password-input/versions

## README

<div align="center">
<h1>MUI OTP input</h1>
  <p>An OTP input designed for the React library <a href="https://mui.com/">MUI</a></p>
</div>
<div align="center">

[![license](https://img.shields.io/badge/license-MIT-blue.svg)](https://github.com/viclafouch/mui-otp-input/blob/main/LICENSE)
![ts](https://badgen.net/badge/Built%20With/TypeScript/blue)
[![npm](https://img.shields.io/npm/v/mui-one-time-password-input)](https://www.npmjs.com/package/mui-one-time-password-input)

<div align="center">
  <img src="https://github.com/viclafouch/mui-otp-input/blob/main/mui-otp-input.gif" width="100%" />
</div>


</div>

## Installation

```
// with npm
npm install mui-one-time-password-input

// with yarn
yarn add mui-one-time-password-input

// with pnpm
pnpm add mui-one-time-password-input
```

## Usage

```jsx
import React from 'react'
import { MuiOtpInput } from 'mui-one-time-password-input'

const MyComponent = () => {
  const [otp, setOtp] = React.useState('')

  const handleChange = (newValue) => {
    setOtp(newValue)
  }

  return (
    <MuiOtpInput value={otp} onChange={handleChange} />
  )
}
```

## Next.js integration

Learn how to use MUI OTP Input with [Next.js](https://nextjs.org/).

Once you have installed `MUI OTP Input` in your next.js project, it is important to transpile it as it is an ESM package first.

```js
// next.config.mjs
/** @type {import('next').NextConfig} */
const nextConfig = {
  transpilePackages: ['mui-one-time-password-input'],
  // your config
}

export default nextConfig
```

## [Documentation](https://viclafouch.github.io/mui-otp-input/)

## Changelog

Go to [Github Releases](https://github.com/viclafouch/mui-otp-input/releases)

## TypeScript

This library comes with TypeScript "typings". If you happen to find any bugs in those, create an issue.

### 🐛 Bugs

Please file an issue for bugs, missing documentation, or unexpected behavior.

### 💡 Feature Requests

Please file an issue to suggest new features. Vote on feature requests by adding
a 👍. This helps maintainers prioritize what to work on.

## LICENSE

MIT

---
_Source: https://npm.io/package/mui-one-time-password-input · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
