Trim video without re-encoding

trimming

// what it does

Places -ss/-to before -i so ffmpeg seeks to 00:01:00 using the input index rather than decoding up to it, then -c copy passes the audio and video packets through without re-encoding. The result is a near-instant extraction of the 1:00–2:00 range at the original quality. Reach for this when you want a rough cut of a long file quickly and don't need the boundaries to be frame-exact.

// shell

$ ffmpeg -ss 00:01:00 -to 00:02:00 -i input.mp4 -c copy output.mp4

// gotcha

Because -c copy can't create new keyframes, the start snaps back to the nearest keyframe at or before 00:01:00 — so the clip begins slightly before the point you asked for and its exact length won't be precisely one minute. It still starts cleanly on that keyframe; the frozen/garbled opening frame people sometimes hit comes from output-side seeking with -c copy, not this input seek.