Search documentation

Search components and pages

Calendar

A date field component that allows selecting dates.

June 2026
01

Installation

Add the calendar component with the shadcn CLI.

bash
npx shadcn@latest add https://swiss.ui.unsanity.ai/r/calendar.json
02

Usage

tsx
import { Calendar } from "@/components/ui/calendar"
03

Examples

Default

June 2026
import { Calendar } from "@/components/ui/calendar"

<Calendar mode="single" defaultMonth={new Date()} className="border border-border" />