shadcn.io is an independent project built on shadcn/ui
Email sits above an email field. The placeholder is you@example.com, and it clears once someone types. There is no hint under the field.
Start here for a short value with a visible name. An icon or a prefix inside the field is an Input Group. Base UI in React does not check the address.
Installation
Anatomy

Usage
<Field className="max-w-md">
<FieldLabel htmlFor="newsletter-email">Email</FieldLabel>
<Input id="newsletter-email" placeholder="you@example.com" type="email" />
</Field>FAQ
How does the Email label connect to the input?
FieldLabel names the input. Its htmlFor matches the control's id. The label text is Email.
Why is the label above the input?
orientation defaults to vertical, so the label stacks over the control. Field sets data-orientation to that value.
Why is this input an email field?
type is email. The placeholder is you@example.com, and it clears once someone types.
How wide is the field?
max-w-md on Field caps the width. The label and the input both fill that width in the vertical layout.
API Reference
Field
Sets htmlFor="newsletter-email". The rest is on the Field page.
Input
Sets id="newsletter-email", placeholder="you@example.com" and type="email". The rest is on the Input page.





