Forms

FileInput

Select local files with a picker button, a compact control, or a dropzone.

Basic usage

Specify the accepted types and use ValueText to show the selection. Selected files appear in FormData as File objects. Validate them on the server when submitting data.

No file selected
Select a PDF document.

API

Key props and defaults.

PropValues and behaviorDefault
variantbutton | boxed | compactbutton
acceptstring | MIME type map—
multiplebooleanfalse
maxFilesnumber1 in single-file mode
onFileChange(details) => void—
namestring—