Not affiliated with official shadcn/ui. Visit ui.shadcn.com for official docs.
React URL Input Form
A React form with URL input validation using React Hook Form and Zod url schema for website or portfolio links built with shadcn/ui
Looking to implement shadcn/ui patterns?
Join our Discord community for help from other developers.
Users type messy URLs without protocols or with typos. This React form uses Zod's built-in url validator—invalid formats like example.com without https trigger Please enter a valid URL errors. Built with shadcn/ui Form components with React Hook Form and type equals url for better mobile keyboards, it's perfect for profile settings, portfolio submissions, or social media links where properly formatted URLs matter.
Pattern created by @haydenbleasel
Installation
Related patterns you will also like
Email Input Form
Email validation with format checking
Simple Text Input Form
Basic text validation without URL rules
Phone Input Form
Phone number with regex validation
Simple Input with Label
Basic input without validation
Search Input Form
Search field with validation
Dialog Form
Form inside modal dialog
Questions you might have
React Number Input Form
A React form with number input and min/max range validation using React Hook Form and Zod coerce for age verification built with shadcn/ui
React Phone Input Form
A React form with phone number input and regex validation using React Hook Form and Zod for international formats built with shadcn/ui