caption.burn job burns subtitles permanently into a video. Provide an SRT, VTT, or ASS file as the subtitles input, or omit it to auto-transcribe the audio. Style the text with web-hex colors, an outline, a background box, and a position.
Accepts: video · Type:
caption.burnRequest
subtitles to auto-transcribe. The spoken language is detected by default (language: "auto"). Pass an ISO-639-1 code to skip detection.
What inputs does it take?
string
required
URL of the source video to caption.
string
URL of an SRT, VTT, or ASS subtitle file. A provided ASS file is burned as-is, preserving its own styling. Omit to auto-transcribe the audio.
string
URL of your own font file (TTF, OTF, TTC, WOFF, WOFF2). Captions render in it, and it takes priority over
fontFamily, so you do not need to know the family name inside your own file. An uploaded asset’s content URL works here.Parameters
enum
default:"auto"
Spoken language for the auto-transcribe path, as an ISO-639-1 code (e.g.
en, es, ja) or auto to detect. English uses a faster model. Everything else routes to multilingual transcription. Ignored when a subtitle file is provided.string
default:"Inter"
Font family, or a CSS fallback stack. Any Google Fonts family works by name and is fetched at render time. Seven are bundled and resolve instantly:
Inter, Roboto, Montserrat, Poppins, Oswald, Anton, Bebas Neue. A stack falls through in order, so "Lato, Inter, sans-serif" tries each in turn. To render in your own file, pass its URL as the font input, which wins over this parameter.string
deprecated
Deprecated alias for
font. Still accepted so existing clients keep working. font wins when both are present.integer
default:"48"
Font size in output pixels. Range 8–400.
string
default:"#FFFFFF"
Text fill color as web hex (
#RRGGBB or #AARRGGBB, alpha first).boolean
default:"true"
Render the text bold.
boolean
default:"false"
Render the text italic.
string
default:"#000000"
Outline (stroke) color as web hex.
number
default:"2"
Outline thickness in pixels. Range 0–20.
number
default:"1"
Drop-shadow depth in pixels. Range 0–20.
0 disables the shadow.boolean
default:"false"
Draw a filled background box behind the text (the accessibility “subtitle bar”).
string
default:"#000000"
Background box color as web hex. Applies when
boxEnabled is true.number
default:"0.6"
Background box opacity,
0 (transparent) to 1 (opaque).enum
default:"bottom"
Vertical placement. One of
bottom, center, top.enum
default:"center"
Horizontal alignment. One of
left, center, right.integer
default:"60"
Vertical margin in pixels. Range 0–2000.
integer
default:"40"
Horizontal margin in pixels. Range 0–2000. Also bounds the line-wrap width.
integer
Maximum characters per line on the auto-transcribe path. Range 10–80.
See also
- Animated captions: word-level captions generated from the audio
- ffprobe: check the subtitle streams already in a file
- Compose: assemble the video before you burn subtitles onto it
- Error codes: the full error catalogue
- Plan limits: duration and file-size caps per plan