Change Video Playback Speed with FFmpeg
Make a video play faster or slower by adjusting video timestamps and audio tempo together, so picture and sound stay in sync.
Run ffmpeg -i input.mp4 -vf "setpts=0.5*PTS" -af "atempo=2.0" output.mp4 to double the playback speed (setpts=2*PTS with atempo=0.5 to halve it).
01Command
Command
$ ffmpeg -i input.mp4 -vf "setpts=0.5*PTS" -af "atempo=2.0" output.mp402What it does
setpts multiplies each video frame's presentation timestamp: a factor below 1 speeds the video up, above 1 slows it down. The audio side is handled by atempo, which shifts tempo without changing pitch, so voices still sound natural. The two factors must be reciprocals of each other or the picture and sound drift out of sync; for very slow playback below 0.5x, chain two atempo filters like atempo=0.5,atempo=0.5 because a single filter cannot go below 0.5.
03Risk
!Warning: Keep setpts and atempo as exact reciprocals (e.g. 0.25*PTS with atempo=4.0) or audio will gradually drift out of sync with the picture.
04Undo
✓No undo needed — this command does not change persistent state.
05Sources
- ffmpeg(1) — Linux manual pageEvidence: Documents -vf and -af filter chain application to the output file.
- FFmpeg Filters Documentation (setpts, atempo)Evidence: setpts scales presentation timestamps to change video speed; atempo changes audio tempo with a supported range of 0.5 to 100 (chaining covers lower rates).
Last verified: 2026-09-18 · Category: Media