Why Do This in Your Browser?
Trimming a video — picking a start and end point and discarding the rest — is the single most common video edit. Yet it's strangely hard to do well online: cloud tools upload your file, paid editors want a subscription, and desktop apps require installing software for a 30-second job.
This tool puts a frame-accurate trim in your browser. Drop a video, scrub the timeline to the start and set the in-point, scrub to the end and set the out-point, preview the range, export. Stream copy copies the streams without re-encoding and finishes in seconds, but it cannot cut between keyframes, so it starts from the keyframe before your in point; Re-encode cuts exactly.
How It Works
Video is encoded in groups of pictures (GOPs) — chunks of frames that depend on a single keyframe. Cutting between keyframes requires re-encoding the partial GOP; cutting on a keyframe is free. You choose the mode: stream copy is fast and lossless but starts at a keyframe, re-encode cuts exactly.
For precision, focus the timeline and use the arrow keys to step one frame and Page Up / Page Down to jump between keyframes, then set the in or out point from the playhead; you can also type points in seconds.
Tip: After trimming, shrink the result to a target file size with the Video Compressor. Trim multiple segments separately, then join them with the Video Merger for a multi-cut edit.
Common Use Cases
Worked example: cutting 3.0–7.0 s from a clip with keyframes every 1.6 s
When a file loads, the trimmer reads its keyframes and frame rate with FFmpeg (decoding keyframes only where the decoder allows) and draws them as yellow ticks on the timeline. Click or drag the timeline to move the playhead, step one frame or jump to the previous or next keyframe with the buttons (or the arrow and Page Up/Down keys with the timeline focused), and set the in and out points from the playhead or by typing seconds. In stream-copy mode the timeline stripes the part before your in point that the copy has to include, and the cut is made at that keyframe.
On October 13, 2026 we checked it in Chromium with FFmpeg.wasm on a 10 s, 30 fps test clip with a keyframe every 48 frames, as H.264 MP4 and as VP9 WebM, and read the outputs with ffprobe (desktop FFmpeg 6.1.1):
| Mode | Arguments | Video frames in file | Plays as | Frames hidden |
|---|---|---|---|---|
| Stream copy, previous version | -ss 3.0 -i in.mp4 -t 4 -c copy | 164 | 4.10 s | 41 (1.37 s, behind an MP4 edit list) |
| Stream copy, now | -ss 1.6 -i in.mp4 -t 5.4 -c copy -avoid_negative_ts make_zero | 164 | 5.55 s, from the 1.6 s keyframe | 0 |
| Re-encode | -ss 3.0 … -c:v libx264 -crf 20 | 120 | 4.00 s, from 3.0 s | 0 |
- Stream copy can only start on a keyframe. The previous version asked FFmpeg for 3.0 s; FFmpeg copied from the 1.6 s keyframe anyway and wrote an edit list telling players to skip 1.37 s. Players that ignore edit lists, including some editors, showed those 41 frames. Now the cut is made at the keyframe itself, so the file plays exactly what it contains, and the timeline shows the extra part before you export.
- Re-encode is exact. 120 frames (4.00 s at 30 fps) starting on the 3.0 s frame, at the cost of one generation of quality at CRF 20 and a much longer run in the browser.
- The timeline matches FFmpeg. Keyframe ticks for the WebM: 0.007, 1.607, 3.207 … 9.607 s, the same 7 times desktop FFmpeg reports. Ten frame steps from the start showed frame 10: compared with frames 8 to 12 extracted by desktop FFmpeg, frame 10 differed by a mean squared error of 0.8 and its neighbours by 4.2 to 13.
- Preview needs a format the browser can play. The timeline, frame stepping and preview use the browser's video player; files it cannot decode (some MKV or AVI files, HEVC in some browsers) still trim, with in and out points typed in seconds.
- Pick by how far apart your keyframes are. Phone and camera footage often has a keyframe every 1–2 s, screen recordings and some exports far less often; the ticks show which you have.
Sources
Checked on .