Stop Rebuilding UI

Shadcn.io is not affiliated with official shadcn/ui

Form with Checkbox

A React form with multiple Checkbox controls validated using React Hook Form and Zod requiring terms acceptance with optional preferences

Checkbox validation enforces required agreements—terms must be accepted before submission. This React form uses React Hook Form with Zod schema validation for Checkbox fields featuring required terms checkbox using z.boolean refine ensuring true value while marketing and security are optional. Built with FormField horizontal layout and FormMessage inline error display, checkbox validation enforces agreements—perfect for terms acceptance, newsletter preferences, notification settings, or anywhere checkbox consent needs validation preventing submission without required acknowledgment.

Form with Checkbox preview

Scroll to load preview

Installation

FAQ

Was this page helpful?

Sign in to leave feedback.