# Video Frame Extractor 🎞️ (scenes, keyframes, thumbnails) (`tagadanar/video-frame-extractor`) Actor

Extract still frames from video links: evenly spaced, every N seconds, one per scene or at exact times. Files, web pages with a video and HLS streams. One row per frame with a public JPG/PNG/WebP link, plus a contact sheet. $1 per 1,000 frames + $0.002 per video.

- **URL**: https://apify.com/tagadanar/video-frame-extractor.md
- **Developed by:** [Tagada Data](https://apify.com/tagadanar) (community)
- **Categories:** Videos, AI, Developer tools
- **Features:** Limited permissions
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $0.70 / 1,000 frame extracteds

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.
Since this Actor supports Apify Store discounts, the price gets lower the higher subscription plan you have.

Learn more: https://docs.apify.com/actors/running/actors-in-store.md#pay-per-event

## What's an Apify Actor?

An Actor is a serverless cloud program that runs on the Apify platform. It has two run modes.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.

Apify vocabulary and the platform model are defined once, in the agent quickstart at https://apify.com/agents.md.

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For examples already wired to this Actor's own input schema, see the [API](#api) section below.

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).

# README

## Video Frame Extractor: still frames from any video link, one row per frame

Paste video links and get still images back: a fixed number of evenly spaced frames, one frame every N seconds, one frame per shot (scene changes), or frames at the exact times you list. Every frame is saved as a JPG, PNG or WebP image with a public link, and comes as its own row in the dataset with its timestamp, size and the video's details. Each video also gets a contact sheet (a storyboard grid of its frames).

It reads direct video files, web pages that play a video, and HLS streams. ffmpeg runs inside the actor: no install, no server, no API key.

**Price: $1 per 1,000 frames + $0.002 per video** on the free plan ($0.70 per 1,000 frames and $0.0014 per video on Gold). Scenes mode adds $0.02 per minute of video scanned. Blank frames that are skipped, videos that fail and the contact sheet are free. Platform usage is included.

### What it reads

| You paste | What happens |
| --- | --- |
| A direct file link (`.mp4`, `.mov`, `.webm`, `.mkv`, `.avi`, `.ogv`, `.ts`, `.m4v`...) | Large files are read in place with HTTP range requests: only the part around each frame is fetched, so a frame from the middle of a 1 GB file takes a few seconds and nothing is downloaded whole. Small files are downloaded once |
| A web page that plays a video | The actor finds the file in the page (Open Graph `og:video`, the `<video>` player, VideoObject structured data, a download link) and reads it |
| An HLS `.m3u8` stream | Read directly; seeking fetches only the segments it needs |

Not supported, each with a clear note in the run's status message (and free):

- **YouTube**: YouTube asks cloud servers to sign in ("confirm you're not a bot") before it serves a video, so it cannot be read from Apify.
- **TikTok, Instagram, Facebook, X, Vimeo, Twitch, Dailymotion**: these serve their videos only to their own player. Give the direct file link instead.
- **Netflix, Prime Video and other DRM-protected services**: never downloaded.
- Players that load their video with JavaScript after the page opens, and pages behind a login.

### Modes

| Mode | What you get | Good for |
| --- | --- | --- |
| `count` (default) | Exactly N evenly spaced frames (`frameCount`, 10 by default). A short clip never returns more frames than it really has | Thumbnails, consistent samples for an AI model |
| `interval` | One frame every N seconds from the start (`intervalSeconds`) | Lectures, recordings, monitoring footage |
| `scenes` | The first frame of each shot, found by decoding the whole video and scoring how much each frame differs from the one before (`sceneThreshold`, 0.3). The opening shot comes first; cuts closer than one second are merged; above `maxFramesPerVideo` the strongest cuts are kept | Storyboards, trailers, ads, summaries for vision models |
| `timestamps` | Frames at the exact times you list: `90`, `1:30` or `00:01:30.500`. Times past the end are listed in the status, not charged. Filling in `timestamps` with the mode left on `count` also uses this mode | Known moments, QA checks |

`maxFramesPerVideo` (50 by default, 500 max) caps interval, scenes and timestamps modes.

**Skip blank frames** (on by default): a black, faded-out or single-colour frame is replaced by the next frame with content in the following 2 seconds; if there is none, it is dropped and not charged. Title cards (text on black) are kept.

**Image options**: `imageFormat` (`jpg`, `png` lossless, `webp`), `maxWidth` (1280 by default; wider frames are scaled down keeping the aspect ratio, smaller ones are never scaled up; 0 keeps the original size).

### What you get

One row per frame:

| Field | Description |
| --- | --- |
| `imageUrl` | Public link to the image (opens without an Apify login, so you can pass it straight to an AI model, a spreadsheet or your CMS) |
| `imageKey`, `imageFormat`, `width`, `height`, `bytes` | The image's key in the run's key-value store, its format, size in pixels and in bytes |
| `timestampSeconds`, `timecode` | The exact time of the frame in the video (the real frame's time, read back from the decoder), in seconds and as `hh:mm:ss.mmm` |
| `frameIndex`, `framesInVideo` | Position of the frame in this video's frames (1 = first) and how many were delivered for it |
| `sceneScore` | Scenes mode: how strong the cut is, from 0 to 1 (empty for the opening shot and in other modes) |
| `contactSheetUrl` | Public link to the video's contact sheet (a grid of its frames) |
| `mode` | The mode used |
| `videoUrl`, `mediaUrl`, `sourceType`, `pageTitle` | The link you gave, the video file or stream read, how it was found (`file`, `page`, `stream`) and the page title |
| `videoDurationSeconds`, `videoWidth`, `videoHeight`, `fps`, `videoCodec`, `container`, `fileSizeBytes` | The video's details |
| `extractedAt` | When the frame was extracted |

The images and contact sheets are files in the run's key-value store: download them all from the run's Storage tab or through the API.

#### Example row (real, from a run on 2026-10-23, signature shortened)

```json
{
  "videoUrl": "https://upload.wikimedia.org/wikipedia/commons/b/b3/Big_Buck_Bunny_Trailer_400p.ogv",
  "mediaUrl": "https://upload.wikimedia.org/wikipedia/commons/b/b3/Big_Buck_Bunny_Trailer_400p.ogv",
  "sourceType": "file",
  "pageTitle": null,
  "mode": "count",
  "frameIndex": 1,
  "framesInVideo": 8,
  "timestampSeconds": 2.08,
  "timecode": "00:00:02.080",
  "sceneScore": null,
  "imageUrl": "https://api.apify.com/v2/key-value-stores/s4S3BL91jkhiTzJdp/records/v001-f0001-000002080ms.jpg?signature=...",
  "imageKey": "v001-f0001-000002080ms.jpg",
  "imageFormat": "jpg",
  "width": 720,
  "height": 400,
  "bytes": 12549,
  "contactSheetUrl": "https://api.apify.com/v2/key-value-stores/s4S3BL91jkhiTzJdp/records/v001-contact-sheet.jpg?signature=...",
  "videoDurationSeconds": 32.997,
  "videoWidth": 720,
  "videoHeight": 400,
  "fps": 25,
  "videoCodec": "theora",
  "container": "Ogg",
  "fileSizeBytes": 4360399,
  "extractedAt": "2026-10-23T13:58:21.217Z"
}
```

### Input examples

Eight evenly spaced frames from each video, 1024 px wide WebP:

```json
{
  "videoUrls": ["https://media.w3.org/2010/05/sintel/trailer.mp4"],
  "mode": "count",
  "frameCount": 8,
  "imageFormat": "webp",
  "maxWidth": 1024
}
```

One frame per shot, up to 30 per video:

```json
{
  "videoUrls": ["https://upload.wikimedia.org/wikipedia/commons/1/18/Big_Buck_Bunny_Trailer_1080p.ogv"],
  "mode": "scenes",
  "sceneThreshold": 0.3,
  "maxFramesPerVideo": 30
}
```

A frame every 30 seconds of a long recording, and exact moments from another:

```json
{
  "videoUrls": ["https://download.blender.org/demo/movies/ToS/tears_of_steel_720p.mov"],
  "mode": "interval",
  "intervalSeconds": 30,
  "maxFramesPerVideo": 100
}
```

```json
{
  "videoUrls": ["https://test-streams.mux.dev/x36xhzz/x36xhzz.m3u8"],
  "mode": "timestamps",
  "timestamps": ["0:05", "1:30", "00:10:00.500"]
}
```

### Use cases

- **Video understanding with AI**: vision models (GPT, Claude, Gemini) read images, not video. Send them 8 to 20 frames, or one per scene, with their timestamps.
- **Thumbnails and posters** for a video page, a course, a product clip or a CMS.
- **Storyboards and contact sheets** to review footage or ad creatives at a glance.
- **Dataset building**: sample frames at a fixed rate or per shot from footage you are allowed to use.
- **Moderation and QA**: sample user uploads or a batch of exports and look for black intros, wrong slates or missing frames.

### Pricing

| What | Free plan | Gold |
| --- | --- | --- |
| Per frame delivered | $0.001 ($1 per 1,000) | $0.0007 |
| Per video that delivered at least one frame | $0.002 | $0.0014 |
| Scenes mode, per minute of video scanned | $0.02 | $0.014 |
| Per run | $0.001 | $0.001 |

Examples on the free plan: 100 product videos at 8 frames each = 100 x $0.002 + 800 x $0.001 = $1.00 (plus $0.001 for the run). One 2-hour lecture at a frame per minute = $0.002 + 120 x $0.001 = $0.12. A 3-minute trailer in scenes mode with 25 shots = $0.002 + 3 x $0.02 + 25 x $0.001 = $0.087.

A scanned minute is a minute of video up to 1080p at 30 fps; larger or faster video counts proportionally more (4K at 60 fps counts about 9 minutes per minute), because decoding it costs that much more. Set a maximum charge for the run and the actor stops extracting before going over it, with a note in the status.

Videos served very slowly (some hosts refuse Apify's servers and are read through a slower route) are stopped once reading them would cost more than their frames earn; the frames already extracted are delivered and the status names the video. On such hosts scenes mode is not available (scanning a whole video through the slow route costs more than it sells for): use count, interval or timestamps.

### FAQ

**How do I extract frames from an MP4 online, without installing ffmpeg?** Paste the link, pick a mode and run. The images are in the run's key-value store and every row has a public link to its image.

**Can I get one frame per scene change?** Yes, mode `scenes`. Lower `sceneThreshold` (0.2) finds soft cuts and slow fades too, higher (0.5) only hard cuts.

**Can I extract the keyframes of a video?** Scenes mode returns the key frame of each shot, which is what most people mean by keyframes. The encoder's own I-frames are not offered as a mode.

**Does it work with YouTube or TikTok links?** No. YouTube refuses cloud servers without a sign-in, and TikTok, Instagram and similar platforms serve their video only to their own player. Use the direct video file link.

**How big can the video be?** Files larger than the run's disk are read in place with range requests (count, interval and timestamps modes fetch only what they need; scenes mode reads the file once from start to end). Files on a host that does not support range requests are downloaded, up to about 45% of the run's free disk (about 460 MB).

**Why are some frames not exactly at the time I asked?** With "Skip blank frames" on, a black frame is replaced by the next frame with content within 2 seconds. Turn it off for the exact planned times. `timestampSeconds` is always the real time of the delivered frame.

**Which formats work?** What ffmpeg 7.1 decodes. Tested on Apify: H.264 in MP4, MOV, MKV and HLS; VP8 and VP9 in WebM (up to 4000x2250 at 60 fps); Theora in Ogg.

**How long are the images kept?** As long as the run's storage: 7 days by default on Apify (longer on paid plans, or copy them to your own storage).

Something not working? Open an issue on the Issues tab with the run link.

Related: [Media Transcriber](https://apify.com/tagadanar/media-transcriber) turns the same kinds of links into text and subtitles.

video frame extractor, extract frames from video, video to images, video thumbnail generator, scene detection, keyframe extractor, contact sheet, storyboard, video screenshots, frames for AI vision, ffmpeg online

# Changelog

This Actor's version history is a separate document: https://apify.com/tagadanar/video-frame-extractor/changelog.md

# Actor input Schema

## `videoUrls` (type: `array`):

Direct video file links (MP4, MOV, WebM, MKV, AVI, Ogg, MPEG-TS...), web pages that play a video file (the page's og:video, \<video> tag or VideoObject is read), or HLS .m3u8 stream links. One per line, up to 100 per run. YouTube, TikTok, Instagram, Vimeo and DRM services (Netflix, Prime Video...) are not supported.

## `mode` (type: `string`):

<b>count</b>: a fixed number of evenly spaced frames. <b>interval</b>: one frame every N seconds. <b>scenes</b>: one keyframe per shot, at each scene change (the whole video is decoded, charged per scanned minute). <b>timestamps</b>: frames at the exact times you list.

## `frameCount` (type: `integer`):

How many evenly spaced frames per video. A short clip never returns more frames than it really has.

## `intervalSeconds` (type: `number`):

One frame every this many seconds, from the start of the video. Decimals work (2.5).

## `timestamps` (type: `array`):

Times to grab, one per line: seconds (90 or 90.5), mm:ss (1:30) or hh:mm:ss.mmm (00:01:30.500). Times past the end of a video are listed in the run status and not charged. Filled in while "Which frames" is left on count, these timestamps are used.

## `sceneThreshold` (type: `number`):

How different two frames must be to count as a new shot, from 0.05 to 0.95. Lower finds more cuts (0.2 for soft cuts and slow fades), higher only hard cuts. 0.3 suits most edited video.

## `maxFramesPerVideo` (type: `integer`):

Cap for interval, scenes and timestamps modes. In scenes mode the strongest cuts are kept.

## `imageFormat` (type: `string`):

JPEG is the smallest for photos and video, PNG is lossless, WebP is smaller than JPEG at the same quality.

## `maxWidth` (type: `integer`):

Wider frames are scaled down to this width, keeping the aspect ratio; smaller videos are never scaled up. 0 keeps the original resolution.

## `skipBlankFrames` (type: `boolean`):

A black, faded-out or single-colour frame is replaced by the next frame with content in the following 2 seconds; if there is none it is dropped and not charged. Title cards (text on black) are kept. Turn off to get frames at the exact planned times.

## `contactSheet` (type: `boolean`):

Also save one grid image of each video's frames (a storyboard), free. Its link is on every frame row.

## Actor input object example

```json
{
  "videoUrls": [
    "https://media.w3.org/2010/05/sintel/trailer.mp4",
    "https://upload.wikimedia.org/wikipedia/commons/b/b3/Big_Buck_Bunny_Trailer_400p.ogv"
  ],
  "mode": "count",
  "frameCount": 4,
  "intervalSeconds": 10,
  "sceneThreshold": 0.3,
  "maxFramesPerVideo": 50,
  "imageFormat": "jpg",
  "maxWidth": 1280,
  "skipBlankFrames": true,
  "contactSheet": true
}
```

# Actor output Schema

## `results` (type: `string`):

One row per extracted frame in the default dataset.

## `images` (type: `string`):

The image files in the run's key-value store.

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "videoUrls": [
        "https://media.w3.org/2010/05/sintel/trailer.mp4",
        "https://upload.wikimedia.org/wikipedia/commons/b/b3/Big_Buck_Bunny_Trailer_400p.ogv"
    ],
    "mode": "count",
    "frameCount": 4
};

// Run the Actor and wait for it to finish
const run = await client.actor("tagadanar/video-frame-extractor").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = {
    "videoUrls": [
        "https://media.w3.org/2010/05/sintel/trailer.mp4",
        "https://upload.wikimedia.org/wikipedia/commons/b/b3/Big_Buck_Bunny_Trailer_400p.ogv",
    ],
    "mode": "count",
    "frameCount": 4,
}

# Run the Actor and wait for it to finish
run = client.actor("tagadanar/video-frame-extractor").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
for item in client.dataset(run.default_dataset_id).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "videoUrls": [
    "https://media.w3.org/2010/05/sintel/trailer.mp4",
    "https://upload.wikimedia.org/wikipedia/commons/b/b3/Big_Buck_Bunny_Trailer_400p.ogv"
  ],
  "mode": "count",
  "frameCount": 4
}' |
apify call tagadanar/video-frame-extractor --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,tagadanar/video-frame-extractor"
        }
    }
}
```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/NaNqpEzZbeDCuX76M/builds/gGP0uMtl99gdP2tdm/openapi.json
