Skip to content
Free Subtitle Converter
Language
Color theme
Support us

TTML to VTT converter

Captions delivered as TTML or DFXP, for broadcast or a streaming service, cannot be added to a web page with the HTML track element. Convert them to WebVTT, the caption format browsers read, and keep every caption’s timing, line breaks and italics.

Convert your subtitle file

Subtitle fileStays on your device

Drop subtitle files here

SRT, VTT, ASS, SBV, TTML, SUB, SMI, LRC and more · up to 100 files

Or paste subtitle text
No file at hand?

Your file is read by this page in your browser. It is not uploaded anywhere.

How to use it

  1. Open the TTML or DFXP file

    Drop the .ttml, .dfxp or .xml file. Times in frames or ticks are converted with the rates the file declares.

  2. Check the WebVTT preview

    VTT is already selected. Compare the first and last caption times with your video.

  3. Download the .vtt file

    Add it to your video with a track element, or upload it to your web player.

What changes from TTML to VTT

Every timed p element becomes a WebVTT cue. Clock, frame, tick and offset times are turned into milliseconds with the frame rate and tick rate declared in the file, and begin times on a parent div are added. Italic, bold and underline, set on the element or through a named style, become <i>, <b> and <u>.

Regions, positions, colors, fonts and background boxes are removed. WebVTT can position cues, but the converter does not carry TTML layout across, so every caption appears in the default place at the bottom.

Before and after

The same TTML file as WebVTT. The frame-based end time 00:00:03:12 at 25 frames per second becomes 00:00:03.480, the duration on the second paragraph gives it an end of 00:00:06.250, and the italic style becomes <i>.

Your TTML file
<tt xmlns="http://www.w3.org/ns/ttml" xmlns:tts="http://www.w3.org/ns/ttml#styling"
    xmlns:ttp="http://www.w3.org/ns/ttml#parameter" ttp:frameRate="25">
  <head><styling><style xml:id="it" tts:fontStyle="italic"/></styling></head>
  <body><div>
    <p begin="00:00:01:00" end="00:00:03:12" style="it">Where were you last night?</p>
    <p begin="4s" dur="2.25s" region="bottom">At the station,<br/>waiting for you.</p>
  </div></body>
</tt>
The VTT file you download
WEBVTT

00:00:01.000 --> 00:00:03.480
<i>Where were you last night?</i>

00:00:04.000 --> 00:00:06.250
At the station,
waiting for you.

Using the result on your site

Upload the .vtt file next to the video and reference it from a track element with a srclang and a label. If you want the captions to look closer to the original, style them with the ::cue selector in your CSS.

More about these formats: XML subtitles explained: TTML, DFXP and IMSC

Questions and answers

Does it read DFXP files?

Yes. DFXP files use the same structure, so .dfxp files convert the same way, including those timed in ticks.

What about IMSC or EBU-TT files?

Text-based files in those profiles are TTML too: their words, times and italics are read, including elements with a prefix such as tt:p. Image-based IMSC captions contain pictures and cannot be converted.

Will the captions keep their positions?

No. Every caption is shown at the bottom center. Add WebVTT cue settings such as line:10% by hand to move individual captions.

Buy me a coffee