Attach files to a task
File upload gives users a clear, accessible way to attach documents, images, or other files as part of completing a form or workflow.
Allows users to upload files of various sizes and formats.
File upload gives users a clear, accessible way to attach documents, images, or other files as part of completing a form or workflow.
Once a file is selected, the component confirms the filename and size so users know their upload was received before submitting.
File type and size restrictions can be communicated upfront, reducing failed uploads and back-and-forth with users.
Upload button
Selected file list
Feedback area
The file upload component provides a button for attaching files and displays selected file names.
Renders an upload control with a file selection button and attachment feedback. Use when users need to submit supporting documents or media as part of a form.
Component tokens are specific to each component. Use the table title as the prefix: border-color-muted under sgds/file-upload means sgds/file-upload/border-color-muted.
sgds/border-color-mutedsgds/color-mutedsgds/form/border-radius/mdsgds/form/border-width/defaultsgds/form/gap/2-xlsgds/form/gap/lgsgds/form/gap/mdsgds/form/gap/xlsgds/form/padding/xsgds/form/padding/ysgds/form/success/color/defaultsgds/form/surface/defaultUse clear labels, predictable values, and a single obvious action for the control.
Too many repeated controls or unclear prompts make form completion slower and less confident.
TabShift+TabEnterSpaceShare them with us on
Report it on GitHub
The Singapore Government Design System was developed to empower teams in creating fast, accessible and mobile-friendly digital services.