RE

React Datepicker

react-datepicker

A simple and reusable datepicker component for React

Component Libraries
react
datepicker
calendar
date
react-component
react-datepicker
Component Libraries
javascript
npm
frontend
Stars
8.4k
Weekly
4.6M
Open issues
96
Bundle
~25 kB

Installation

npm install react-datepicker

Code example

import { Button } from "react-datepicker";

export function Example() {
  return (
    <div className="flex gap-2">
      <Button>Primary</Button>
      <Button variant="outline">Secondary</Button>
    </div>
  );
}

Pros & cons

Pros

  • Actively maintained by HackerOne
  • 4.6M weekly downloads. Battle tested
  • First-class TypeScript definitions
  • MIT licensed

Considerations

  • Adds roughly ~25 kB to your bundle
  • Needs client-only rendering in SSR frameworks
  • Not supported in React Native
  • 96 open issues on GitHub

FAQs

Alternatives & similar libraries