
Laravel News · 3 min readWeb performance
Laravel FFmpeg 9: Encode Video and Stream HLS and DASH
Laravel FFmpeg 9 replaces the old PHP-FFMpeg wrapper with Laravel’s own Process, Storage, Http, and Queue features, enabling streamlined video export, adaptive HLS/DASH streaming, encryption, and queued conversions. The guide shows how to configure, encode, and serve protected streams using signed URLs and Laravel’s routing.
- Use FFMpeg::disk()->open()->export()->resize()->video()->audio()->toDisk()->save() for simple 480p export.
- Configure adaptive HLS with ->hls()->variant()->encrypt()->toDisk()->save() and set rotateEvery for key rotation.
- Queue conversions with ->queued(queue:'video',parallel:true) and monitor progress via onProgress().