Join videos with FFmpeg

Joins clips end to end, copying streams when the inputs already match.

ffmpeg -i https://cdn.rendobar.com/assets/examples/sample.mp4 -i https://cdn.rendobar.com/assets/examples/sample.mp4 -filter_complex "[0:v][0:a][1:v][1:a]concat=n=2:v=1:a=1[v][a]" -map "[v]" -map "[a]" -t 8 out.mp4
Encode
1768 ms
Output
780.4 KB
Cost
$0.0033
Result
1280x720

job_12f3d6e2ad514364

The part everyone gets wrong

There are two different concats and they solve different problems. The concat DEMUXER copies streams and is instant, but it requires identical codecs, resolution and timebase. The concat FILTER, used here, re-encodes and accepts mismatched inputs. Reaching for the demuxer on mismatched files is where the corrupted-output reports come from.

Frequently asked questions

How do I concat videos ffmpeg?

Joins clips end to end, copying streams when the inputs already match.

What goes wrong most often?

There are two different concats and they solve different problems. The concat DEMUXER copies streams and is instant, but it requires identical codecs, resolution and timebase. The concat FILTER, used here, re-encodes and accepts mismatched inputs. Reaching for the demuxer on mismatched files is where the corrupted-output reports come from.

Do I need FFmpeg installed?

Not with Rendobar. The command on this page ran through the API against a URL, with no local FFmpeg and no server. The job id below it is the job that produced these numbers.

Run this without installing FFmpeg

This exact command ran through the API against a URL.