- How do I install sopamo/laravel-filepond in a Laravel application?
- Run composer require sopamo/laravel-filepond in the root of your Laravel project. The service provider is auto-discovered, so no manual registration is needed. If you want to change defaults such as the temporary files disk, publish the config with php artisan vendor:publish --provider="Sopamo\LaravelFilepond\LaravelFilepondServiceProvider". After that, point FilePond's server option at the package's /filepond/api routes.
- Which Laravel and PHP versions does laravel-filepond support?
- The v2 line targets Laravel 12 and Laravel 13, and Laravel 11 and earlier are explicitly dropped. PHP 8.2 or newer is required, and PHP 8.3 or newer is required when paired with Laravel 13. Treat that runtime floor as a platform-wide constraint because it can force end-of-life upgrades across your whole dependency graph. The package is Laravel-specific and is not usable in Symfony, Lumen, or other frameworks.
- Does laravel-filepond handle chunked uploads out of the box?
- Yes. The package handles temporary uploads, chunked uploads, and file reverting without you writing custom controllers. The original file name is sent from the client via the Upload-Name header so chunked uploads can be stitched together correctly. In v2, invalid chunk ranges and oversized integer headers are rejected before anything is written to storage, which prevents orphaned empty chunks from consuming space. Azure users must also send the original file's Content-Type when initializing a chunked upload.
- How do I move a FilePond temporary upload to its final location in Laravel?
- Resolve the package class with app(\Sopamo\LaravelFilepond\Filepond::class) and call getPathFromServerId with the serverId that was returned by the upload request. Read the file from the disk configured in filepond.temporary_files_disk, then move or copy it to your final destination using Storage or the File facade. If the temporary disk and the final destination are different disks, copy the file first and delete the temporary file yourself, because the package will not do it for you.
- Can I use S3 or Azure instead of the local disk for temporary FilePond uploads?
- Yes, any Laravel filesystem disk can be configured as the temporary storage through the filepond.temporary_files_disk config value. If you keep the default local disk, make sure the storage/app/filepond directory exists and is writable, otherwise uploads will fail. Version 2 adds Azure block staging and commitment so chunked uploads no longer require downloading the full file again, which closes the biggest historical gap versus S3. Custom or non-standard backends may still need extra testing before you rely on them.
- What FilePond JavaScript configuration is required for this Laravel backend?
- Set FilePond's server option to url '/filepond/api' with process pointing at '/process', revert at '/process', and patch at '?patch='. Pass your X-CSRF-TOKEN in the headers so Laravel's CSRF middleware accepts the requests. The process headers callback should also return Upload-Name with the original file name, which is what the backend uses for chunked uploads. If you use Azure, include the file's Content-Type on chunked upload initialization as well.
- How does reverting work and how are temporary files deleted?
- FilePond calls the revert URL you configured, typically '/process', and the package's controller removes the temporary upload from the configured disk. Server IDs are validated before deletion, and historical server IDs from older versions remain supported, which limits the blast radius if you are upgrading. Keep the revert route behind the same middleware and CSRF setup as the upload route. If you move files across disks yourself, remember the temporary copy is your responsibility to clean up.
- Is laravel-filepond ready for production use?
- The current 2.0.0 release line is a beta, with 2.0.0-beta.5 as a pre-release, so there is no semver stability guarantee and the API surface may still shift before general availability. Pin the exact version rather than using a caret constraint, stage it in a non-production environment first, and define an explicit rollback to 1.6.0. For production systems, wait for a GA signal or a documented freeze point before adopting.
- How do I test laravel-filepond, both its own suite and my integration?
- For package development, run composer install and then ./vendor/bin/phpunit; the maintainers suggest running it inside a Docker container built from the composer image. In your own application, add feature tests that post real multipart requests to the /filepond/api routes and assert the returned serverId resolves through getPathFromServerId. Exercise the new pre-write rejection behavior for invalid chunk ranges and oversized headers, and assert Azure clients send Content-Type on chunked upload initialization. FormRequest and middleware integration surfaces reported no breaking changes, so existing validation hooks should still apply.
- Is upgrading from laravel-filepond 1.6 to 2.0 a drop-in Composer bump?
- No. Version 2.0.0 is a deliberate architectural reset with a refactored upload pipeline and reworked chunk handling, and it also raises the floor to PHP 8.2 and Laravel 12. Plan it as a coordinated platform upgrade covering PHP, Laravel, and the package rather than a simple dependency update. Also audit Azure chunked-upload clients for the new Content-Type requirement and update client error handling, since invalid chunks are now rejected instead of silently written.