Skip to content

vercel-labs/ffmpeg-on-vercel

Repository files navigation

FFmpeg on Vercel

FFmpeg runs natively on Vercel's Fluid compute without modifications.

See route.ts for sample usage based on ffmpeg-static package from npm.

Note, that you need to declare the binary to be included in your function.

Recommendation

Since FFmpeg takes full advantaged of available cores, we recommend increasing CPU/RAM with a configuration like this. Because Vercel's cost increases linearly with CPU availability, this increases performance, yet can be essentially cost-neutral for a CPU-bound workload like FFmpeg.

[vercel.json]

{
  "$schema": "https://openapi.vercel.sh/vercel.json",
  "functions": {
    "app/convert/route.ts": {
      "memory": 3009
    }
  }
}

Releases

No releases published

Packages

No packages published

Contributors 2

  •  
  •