# Create SRT and VTT subtitles from audio or video

**Use case:** 

Makes ready-to-upload SRT and VTT subtitle files from audio and video links, with line length you choose, plus the plain transcript. Works for 25 European languages detected automatically. This example subtitles a 20-second public-domain LibriVox recording with 42-character lines.

## Input

```json
{
  "fileUrls": [
    "https://api.apify.com/v2/key-value-stores/8EgQG4i7kXacD18DR/records/speech-en-20s.mp3?signature=140VmPhn4rUJ1s5hHAq3c"
  ],
  "includeSegments": true,
  "includeWordTimestamps": false,
  "speakerLabels": false,
  "numSpeakers": 0,
  "maxMinutesPerFile": 240,
  "maxFileSizeMb": 1000,
  "subtitleLineChars": 42
}
```

## Output

```json
{
  "url": {
    "label": "File",
    "format": "link"
  },
  "status": {
    "label": "Status"
  },
  "text": {
    "label": "Transcript",
    "format": "text"
  }
}
```

## How it works

### 1. Sign up on Apify or log in

The Audio & Video Transcription to Text, SRT and VTT Actor is ready to run with the inputs already set for "Create SRT and VTT subtitles from audio or video". [Sign up or log in](https://console.apify.com/create-task-from-example/XQUAnWWuDFBsneaWd) and you'll land in Apify Console with a copy of this exact task.

### 2. Start the "Create SRT and VTT subtitles from audio or video" task

The Audio & Video Transcription to Text, SRT and VTT Actor will start running based on the input automatically. You can also change all the input fields, like file urls, include timestamped segments, and more, to match your specific use case.

### 3. Receive the "Create SRT and VTT subtitles from audio or video" output

Monitor the progress in real time. You will be notified as soon as your dataset is complete and ready for review. Each result includes data such as file, status, and transcript.

### 4. Integrate into your workflow

The final output is delivered in JSON, CSV, or Excel format, ready to be plugged into your workflow. You can also [run the "Create SRT and VTT subtitles from audio or video" task via API](https://apify.com/klarto/audio-video-transcription.md).

## FAQ

### Where are the SRT and VTT subtitle files?

The subtitle task saves an SRT and a VTT file for each input file in the run's key-value store, and the dataset item links to both.

### Can I change the subtitle line length?

Yes. The subtitle task splits lines at the character count you set in Subtitle line length; 42 characters is a common standard for video.

### How much do subtitles cost?

Subtitles cost $0.01 per started audio minute per file, so 10 minutes of video cost $0.10. Files without speech and failed files are free.

## About this Actor

This example demonstrates how to use [Audio & Video Transcription to Text, SRT and VTT](https://apify.com/klarto/audio-video-transcription.md) with a specific input configuration. Visit the [Actor detail page](https://apify.com/klarto/audio-video-transcription.md) to learn more, explore other use cases, and run it yourself.


## How to integrate an Actor?

This Task's input is already configured above. Use it as-is rather than inventing a new one.

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 full API examples (JavaScript, Python, CLI, MCP, OpenAPI), see this Task's Actor page: https://apify.com/klarto/audio-video-transcription.md

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`).
