A long recording is often easier to handle in pieces: you can stay under a platform’s upload size limit, share one chapter at a time, or process the parts in parallel. FFmpeg can split a video into parts without re-encoding. The parts keep the quality of the source, and the split finishes in seconds.
1. Split into Fixed-Length Parts (Segment Muxer)
To cut a video into back-to-back 60-second parts, use the segment muxer. (A muxer writes the output file; this one starts a new file at a set interval.)
ffmpeg -i input.mp4 -c copy -f segment -segment_time 60 -reset_timestamps 1 output_%03d.mp4
This writes output_000.mp4, output_001.mp4, output_002.mp4 and so on, each about 60 seconds long.
-c copy… no re-encoding, so there is no quality loss and it runs fast-f segment… use the segment muxer-segment_time 60… target length of each part in seconds-reset_timestamps 1… start each part’s timestamps at zerooutput_%03d.mp4…%03dbecomes a zero-padded counter (000, 001, …)
| Option | Meaning |
|---|---|
-f segment |
Activate the segment muxer |
-segment_time |
Target seconds per output part |
-reset_timestamps 1 |
Each part starts its clock at 0 |
%03d |
Auto-incrementing 3-digit file index |
2. Why -reset_timestamps 1 Matters
Without -reset_timestamps 1, each part keeps its original timestamps from the source. output_001.mp4 then starts at 60 seconds instead of 0, and some players show a long blank gap before playback begins.
With -reset_timestamps 1, every part starts at 00:00:00 and plays normally on its own. Keep it unless you have a specific reason not to.
3. Cut Out a Single Part by Start and Duration
If you need only one part, such as the first 60 seconds, you don’t need the segment muxer. Give a start time and a duration:
ffmpeg -ss 00:00:00 -t 60 -i input.mp4 -c copy output_part1.mp4
-ss 00:00:00… start position (here, the beginning)-t 60… take 60 seconds from that point-c copy… copy without re-encoding (no quality loss)
For a later part, change the start time. This takes the part from 2:00 to 3:00:
ffmpeg -ss 00:02:00 -t 60 -i input.mp4 -c copy output_part2.mp4
For more on start and end times, including the -to option, see the trimming guide.
4. Keyframe Accuracy — Why Cuts Land Where They Do
When you split with -c copy, FFmpeg can cut only at keyframes (also called I-frames: complete pictures that do not depend on other frames). Cutting between two keyframes requires re-encoding. The segment muxer cuts at the keyframe at or after each requested time, so a part may start a little later than the time you asked for.
| Approach | Cut accuracy | Speed | Quality |
|---|---|---|---|
-c copy (stream copy) |
Snaps to keyframe | Very fast | Lossless |
| Re-encode | Frame-exact | Slower | Re-encoded |
So a 60-second part may really be 58 or 62 seconds, depending on where the keyframes are. For most uses that is fine. If the cut must land on an exact frame, re-encode (next section). The FFmpeg Seeking wiki explains how this works.
5. Split at Exact Times (Re-encoding)
When an exact cut matters more than speed, leave out -c copy and let FFmpeg re-encode. You can then cut at any frame:
ffmpeg -ss 00:00:30 -t 30 -i input.mp4 -c:v libx264 -crf 18 -c:a aac output_exact.mp4
- Without
-c copy, FFmpeg decodes and re-encodes, so it can start exactly at 00:00:30 -crf 18… high quality (lower is better quality, larger file)
It takes longer, but the cut is exact to the frame.
6. Troubleshooting
Issue 1: Parts start with a few black or frozen frames
Cause: With -c copy, the video can start only on a keyframe. If you put -ss after -i and the cut point is not a keyframe, there is no picture until the next keyframe, while the audio already plays. (Parts made by the segment muxer always start on a keyframe.)
Fix: Put -ss before -i as in section 3, or re-encode for an exact start (section 5).
Issue 2: Each part seems to start at the wrong time
Cause: -reset_timestamps 1 is missing, so the parts keep their original timestamps.
Fix: Add -reset_timestamps 1 to the segment command (section 1).
Issue 3: Invalid segment filename template and no files are written
Cause: The output name has no counter such as %03d, so the segment muxer stops without writing any file.
Fix: Put %03d (or a similar counter) in the output name so each part gets its own number.
FAQ
Q1. Does splitting reduce quality?
A. Not with -c copy. The video and audio data are copied unchanged. Only the re-encode method in section 5 changes the video.
Q2. Can I split by file size instead of time?
A. Not directly. The segment muxer splits by time (-segment_time). For a size limit, choose a segment time that keeps each part under the limit (size is roughly bitrate × duration).
Q3. Why is my 60-second segment actually 62 seconds?
A. With -c copy, the segment muxer cuts at the first keyframe at or after each split time, so the lengths vary a little. Re-encode (section 5) if you need exact lengths.
Q4. Can I split a video and join parts back later? A. Yes. The concatenation guide shows how to join the parts again.
Q5. Does this work for MKV or MOV?
A. Yes. The segment muxer works with other containers too. Give the output the matching extension (e.g. output_%03d.mkv).