Files and folders

Cut, join and convert videos with ffmpeg

Trim a clip, stitch videos together and convert formats, without opening an editor.

Fill these in once
  1. Cut a clip (from 1:00 to 2:30)
    Terminal
    ffmpeg -ss 00:01:00 -to 00:02:30 -i video.mov -c copy clip.mp4

    -c copy is instant but cuts at the nearest keyframe. Leave it out for an exact cut.

  2. Convert to MP4
    Terminal
    ffmpeg -i video.mov output.mp4
  3. Join videos: list them first
    Terminal
    printf "file '%s'\n" part1.mp4 part2.mp4 > list.txt
  4. Then join them
    Terminal
    ffmpeg -f concat -safe 0 -i list.txt -c copy joined.mp4
  5. Convert every .mov in a folder to .mp4
    Terminal
    for f in *.mov; do ffmpeg -i "$f" "${f%.mov}.mp4"; done
  1. Cut a clip (from 1:00 to 2:30)
    Terminal · Ubuntu / Debian
    ffmpeg -ss 00:01:00 -to 00:02:30 -i video.mov -c copy clip.mp4

    -c copy is instant but cuts at the nearest keyframe. Leave it out for an exact cut.

  2. Convert to MP4
    Terminal · Ubuntu / Debian
    ffmpeg -i video.mov output.mp4
  3. Join videos: list them first
    Terminal · Ubuntu / Debian
    printf "file '%s'\n" part1.mp4 part2.mp4 > list.txt
  4. Then join them
    Terminal · Ubuntu / Debian
    ffmpeg -f concat -safe 0 -i list.txt -c copy joined.mp4
  5. Convert every .mov in a folder to .mp4
    Terminal · Ubuntu / Debian
    for f in *.mov; do ffmpeg -i "$f" "${f%.mov}.mp4"; done
  1. Cut a clip (from 1:00 to 2:30)
    PowerShell
    ffmpeg -ss 00:01:00 -to 00:02:30 -i video.mov -c copy clip.mp4

    -c copy is instant but cuts at the nearest keyframe. Leave it out for an exact cut.

  2. Convert to MP4
    PowerShell
    ffmpeg -i video.mov output.mp4
  3. Join videos: list them first
    PowerShell
    "file 'part1.mp4'", "file 'part2.mp4'" | Set-Content list.txt
  4. Then join them
    PowerShell
    ffmpeg -f concat -safe 0 -i list.txt -c copy joined.mp4
  5. Convert every .mov in a folder to .mp4
    PowerShell
    Get-ChildItem *.mov | ForEach-Object { ffmpeg -i $_.Name ($_.BaseName + ".mp4") }