Overview
The Blazor File Upload is a component for uploading files, images, documents, and audio and video files to a server. The File Upload works in both WebAssembly and Server-side Blazor apps, and also supports a rich set of features that include multiple file selection, progress bars, auto-uploading, drag and drop, folder (directory) uploading, file validation, and more.
Why choose Syncfusion Blazor File Upload?
Multiple-file upload
Select multiple files and upload them to a server at the same time. This is useful for uploading images to a gallery and for file-sharing applications.
Drag and drop
Upload multiple files by simply dragging them from the file explorer to the drop area (drop zone), which is a more user-friendly way to select and upload multiple files.
Folder upload
Accepts a folder (directory) as a file source for uploading all the files (including subfolders) of the selected folder.
AJAX file uploader
Using the AJAX library, the Blazor File Upload component easily uploads files in asynchronous mode.
Utilize chunk upload for large files
Manage upload of large file uploads efficiently using chunk upload that slices a large file into smaller chunks and uploads to the server in a sequential order asynchronously.
Create your own template designs
Allows users to create a custom UI in the Blazor File Upload based on their application need using a wide range of template options.
Attractive customizable themes
Cutting edge design with 5+ built-in themes such as Fluent, Tailwind CSS, Bootstrap, Material, Fabric, and more. Utilize the online Theme Studio tool to customize themes of File Upload easily.
Globalization and localization
Enables users from different locales to use the File Upload by formatting dates, currency, and numbering to suit their preferences.
Blazor File Upload Code Example
Easily get started with Blazor File Upload using a few simple lines of C# code, as demonstrated below. Also explore our Blazor File Upload Example that shows you how to render the uploader component.
<SfUploader AutoUpload="false"><UploaderEvents ValueChange="OnChange"></UploaderEvents></SfUploader>@code {private void OnChange(UploadChangeEventArgs args){ foreach (var file in args.Files) { var path = @"path" + file.FileInfo.Name; FileStream filestream = new FileStream(path, FileMode.Create, FileAccess.Write); file.Stream.WriteTo(filestream); filestream.Close(); file.Stream.Close(); }}}
Resumable upload
A built-in feature to pause, resume, retry, and cancel a file upload. This helps users upload high-resolution images, videos, and other large files safely. Additionally, it provides an option to pause and resume automatically based on server connection.
- Resumable upload documentation
Custom file upload button
The action buttons of the Blazor File Upload component are completely customizable, including its file list, which allows users create their own design for the Blazor File Upload UI.
- Custom File Upload button documentation
File types (file extensions)
Upload various file types and impose restrictions to allow only valid types of files from the client-side, which is mandatory before uploading a file in the web application.
- File types documentation
File validation (filter)
Users can add validation to check file size limits with minimum and maximum ranges, number of files required, total size, and MIME type before uploading a file to a server.
- File validation documentation
- File validation example
Paste image to upload
The Blazor File Upload component processes images from the clipboard, also. Simply copy and paste the images to be uploaded to a server.
Delete uploaded files
Blazor File Upload provides a simple interface to delete wrongly uploaded files from a server.
Preload uploaded files
Users can configure previously uploaded files from the server with a success state, which is useful for viewing, removing, and manipulating them.
- Preload uploaded files example
- Preload uploaded files documentation
Auto-upload
Users can initiate an automatic upload to upload files immediately upon adding them to the upload queue.
- Auto-upload documentation
Right-to-left (RTL)
The Blazor File Upload component supports right-to-left rendering, which improves the user experience and accessibility for those who work with languages like Hebrew, Arabic, or Persian.
Web accessibility
-
Fully supports WAI-ARIA accessibility, which allows the Blazor File Upload component to be accessed by on-screen readers and assistive devices.
-
Follows the WAI-ARIA Best Practices for implementing keyboard interaction.
-
The UI element visuals, such as foreground color, background color, line spacing, text, and images, were designed based on the WCAG 2.0 standard.
Touch support
The Blazor File Upload component provides the best user experience across phone, tablet, and desktop form factors.
Standard HTML forms
The Blazor File Upload component has form support (synchronous mode) to work with native HTML forms.
- Form validation
Developer-friendly APIs
Developers can control the appearance and behaviors of the Blazor File Upload, including its file list, using a rich set of APIs.
- API documentation
Syncfusion Blazor Resources
Learning
DocumentationTechnical Support
Contact Support Community ForumUI Kits
Sketch Download Adobe XD Download Figma Download