> ## Content Index
> Fetch the complete content index at: https://ffmpeguru.com/llms.txt
> Use this file to discover other available public pages before exploring further.

# Extract a single video frame as a JPEG image
- URL: https://ffmpeguru.com/extract-a-single-video-frame-as-a-jpeg-image/
- Published: 2026-11-26T09:00:00.000Z
- Updated: 2026-11-26T09:00:00.000Z
- Author: FFmpeguru
- Tags: ffmpeg

Grabbing a single frame from a video is useful for thumbnails, previews, or extracting a still for editing. The `-ss` flag seeks to the timestamp; `-frames:v 1` tells FFmpeg to output one video frame and stop.

## The command

```
ffmpeg -ss 00:00:05 -i input.mp4 -vframes 1 frame.jpg
```

## What it does

FFmpeg seeks to 5 seconds in the input, decodes the frame there, and writes a single JPEG. The output is a still image at the source's resolution. The encode is fast — the entire operation takes a fraction of a second.

## When to use it

For generating thumbnails, previews, or stills for documentation. The command makes no assumption about the source other than that it can be opened; the timestamp can be any value within the source's duration.

## Video and audio requirements

Any decodable video. The timestamp can be in seconds (`00:00:05`) or in `HH:MM:SS.MS` format for sub-second precision (`00:00:05.500`). The `-vframes 1` flag is the key: it tells FFmpeg to output exactly one video frame and stop.

## Things to avoid

- Using `-ss` after `-i`. That positions the seek for decode, which is slow. The command above uses input-option seeking, which is fast (the demuxer jumps to the timestamp).
- Expecting a frame exactly at the requested timestamp. The closest keyframe is decoded; if you need frame-accurate extraction, use `-ss` after `-i` and accept the slower seek.
- Forgetting that the output format determines the codec. The `.jpg` extension makes FFmpeg use the JPEG encoder. For PNG, use `.png`; for WebP, use `.webp`.
- Using this for high-quality stills. JPEG is lossy and the default quality is medium. For archival, use PNG or specify `-q:v 1` for the highest JPEG quality (still lossy but visually lossless).