> For the complete documentation index, see [llms.txt](https://diffio.ai/llms.txt). This page is also available as HTML at https://diffio.ai/docs/overview/capabilities/video-support/.

# Video support: restore audio in MP4, MOV, WebM and more

Diffio restores the soundtrack of a video and returns an MP4 with the original picture and the restored audio.

## Watch a restored soundtrack

Watch a restored soundtrack

Real noisy videos, restored November 3, 2026 with Diffio 4.7. Switch soundtracks while the picture plays.

**Fish hatchery, Colorado**

Press play, then switch between Original, 4.7 Flash and 4.7 Pro. The picture and your place stay the same.

**Read what's said**

“As the filter panels clog up in the center of the filter panel, the water rises up. As the filter clogs, eventually it kicks on a float switch to where then it rotates the drum while spraying off the panels.”

Source: A staff member explaining the filtration building at Leadville National Fish Hatchery, July 2010. Video by Stephanie Raine, USFWS, public domain.

**Source & method**

Restored November 3, 2026 with Diffio 4.7 Flash and Diffio 4.7 Pro; the Flash soundtrack is the same excerpt from our [speech enhancer test](https://diffio.ai/speech-enhancer-benchmark/). Every version plays at matched loudness. [Source and license](https://diffio.ai/remove-background-noise-from-video/#sample-sources).

More footage, and how it works for [removing background noise from video](https://diffio.ai/remove-background-noise-from-video/) and [fixing Zoom recordings](https://diffio.ai/fix-zoom-audio/).

## Video workflow

1. **Upload a video** MP4, MOV, WebM and more, with an audio track
2. **Restore the soundtrack**: the picture is left untouched
3. **Download the MP4**: original picture, restored audio

> **Each step in detail**
>
> - Upload a supported video container with an audio track. Diffio detects video inputs from metadata and file type, then prepares the audio for restoration.
> - Diffio restores the audio track and creates preview assets so the result can be reviewed in the project workspace.
> - Paid plans can download a video output with restored audio when the restored video artifact is ready. The download is an MP4 file with the original picture.

## Supported containers and limits

- MP4
- MOV
- WebM
- AVI
- MKV
- 3GP
- 3G2

File size

Up to 2 GB

Length

No length limit in the API

Metering

Source duration, 60 s minimum

Diffio restores audio from video uploads. It does not upscale, denoise, color grade, or repair video frames.

**Extensions, media types and limits in detail**

The app and the API support MP4, MOV, WebM, AVI, MKV, 3GP and 3G2 video containers when they include an audio track and are detected as video.

| Container | File extensions | Media type |
| --- | --- | --- |
| MP4 | `.mp4` | `video/mp4` |
| MOV | `.mov` | `video/quicktime` |
| WebM | `.webm` | `video/webm` |
| AVI | `.avi` | `video/x-msvideo` |
| MKV | `.mkv` | `video/x-matroska` |
| 3GP | `.3gp` `.3gpp` | `video/3gpp` |
| 3G2 | `.3g2` | `video/3gpp2` |

- File size: up to 2 GB (2,147,483,648 bytes) per file, the same limit as audio uploads.
- Length: the API enforces no duration limit on video uploads.
- API usage is metered on the source video's duration, rounded up to whole seconds, with a 60 second minimum per generation.

## API downloads

For a completed video project, [get a playback grant](https://diffio.ai/docs/api-reference/get-generation-media/) returns signed URLs in `files`, and [get transcript](https://diffio.ai/docs/api-reference/get-transcript/) returns the normalized word-timed transcript:

Video project

- `files.video` MP4 with the original picture and restored audio
- `files.audio` The restored MP3 soundtrack on its own
- `transcript` Word-timed JSON from `GET .../transcript` (or raw `files.transcript`)

- URLs in `files` need no `Authorization` header and expire after 6 hours (`expires_at`); append `?download=interview.mp4` to set a file name
- `GET .../media` returns `200` even while `status` is `processing`, naming only files that exist so far; poll [get a generation](https://diffio.ai/docs/api-reference/get-generation/) until `complete` first

> **Readiness and playback rules**
>
> - Poll [get a generation](https://diffio.ai/docs/api-reference/get-generation/) until overall `status` is `complete` before downloading `files.video`.
> - Audio-only projects (`has_video: false`) never include `files.video` or `files.video_hls`.
> - For adaptive streaming, `files.hls_master` carries the picture (`files.video_hls`) with the restored and original audio once `video_preview_status` on the project is `ready`.
> - Preview grants (`?preview_seconds=N`) omit full downloads including `video`, `audio`, `audio_mixed` and `transcript`.

1. Request `GET /v2/projects/{project_id}/generations/{generation_id}/media` `Authorization: Bearer`
2. Response `files.video · files.audio` `status: "complete" · expires_at`

**Download the restored MP4 in Python, Node.js or cURL**

**Python**

```python
from diffio import DiffioClient

client = DiffioClient()
path = client.generations.download(
    project_id,
    generation_id,
    file="video",
    path="interview-restored.mp4",
)
print(path)
```

**Node.js**

```javascript
import { DiffioClient } from "diffio";

const client = new DiffioClient();
const file = await client.generations.download(project.id, generation.id, {
  file: "video",
  path: "interview-restored.mp4",
});
console.log(file.path, file.size_bytes);
```

**cURL**

```bash
VIDEO_URL=$(curl -sS "https://api.diffio.ai/v2/projects/$PROJECT_ID/generations/$GEN_ID/media" \
  -H "Authorization: Bearer $DIFFIO_API_KEY" | jq -r .files.video)
curl -sS -o interview-restored.mp4 "$VIDEO_URL"
```

## Video support questions

### Does Diffio change the picture?

No. Diffio restores the soundtrack and attaches it to the original picture. It does not upscale, denoise, color grade or repair video frames.

### Can I download only the restored audio from a video project?

Yes. Call [get a playback grant](https://diffio.ai/docs/api-reference/get-generation-media/) and fetch `files.audio` for the restored MP3 soundtrack, `files.video` for the MP4 with the original picture, or call [get transcript](https://diffio.ai/docs/api-reference/get-transcript/) for the word-timed transcript.

### How is a video generation billed through the API?

Like audio: on the source video's duration, rounded up to the next whole second, with a 60 second minimum per generation. [Billing](https://diffio.ai/docs/overview/administration/billing/) has the details and [API pricing](https://diffio.ai/api-pricing/) the current rates.

### Which video files can I upload?

MP4, MOV, WebM, AVI, MKV, 3GP and 3G2 files with an audio track, up to 2 GB each, with no length limit through the API. A video without an audio track has nothing to restore.
