TTML to JSON Converter
Convert TTML subtitles to JSON instantly in your browser.
Drop your subtitle file here
or click to browse (multiple files supported)
Supported: TTML, ITT, DFXP
About Converting TTML to JSON
Converting a TTML (.ttml, .dfxp, .itt) file to JSON turns broadcast-grade XML captions into plain structured data, each timed paragraph becomes one JSON object your script or player can consume without an XML parser.
What is TTML?
TTML (Timed Text Markup Language) is an XML-based, W3C-standardized caption format used in broadcast and professional streaming. It supports rich styling, named regions, and precise positioning.
What is JSON Subtitle Export?
JSON (.json) is a structured, machine-readable data format, not a subtitle format any media player reads, but the format developers and data pipelines actually want. Each cue becomes an object with its index, start/end timecodes in both human-readable (HH:MM:SS,mmm) and raw-millisecond form, and the cue text with inline styling tags stripped. It's the export to reach for when you're building a custom player, feeding a subtitle-review tool, or processing captions programmatically instead of opening them in a video app.
About TTML to JSON Conversion
- One object per cue: each TTML
<p>paragraph becomes a JSON object with explicitindex,start/endtimecodes, andtextfields. - XML timecodes normalized to milliseconds: TTML's clock-time attributes (
begin="00:00:01.000") are converted to both a readable timecode and rawstartMs/endMsfields, no XML duration parsing needed downstream. - Styling and regions stripped: TTML's
tts:styling attributes and region layout are dropped, JSON output carries plain cue text only, since JSON has no XML-style attribute convention of its own. - .dfxp and .itt accepted too: broadcast SMPTE-TT (
.dfxp) and iTunes Timed Text (.itt) are the same underlying XML schema as TTML, so this page accepts all three extensions.
All timing is preserved precisely during conversion.
What You Lose vs What You Gain
What You Lose in Conversion
- XML/CSS styling with full control
- Named regions for caption placement
- Precise positioning and alignment
What You Gain in Conversion
- Structured, parseable output any programming language can consume without writing a subtitle parser
- One object per cue with explicit index/start/end/text fields, no line-based format to parse
- Millisecond-precision timestamps alongside human-readable timecodes, ready for custom players and data pipelines
When to Convert TTML to JSON
Data Pipelines & Analysis
Feed cue timing and text into a script, notebook, or ETL pipeline without writing a subtitle-format parser first.
Custom Video Players
Load structured cue data directly into a custom-built player or captioning UI that expects JSON, not a subtitle file.
Review & QA Tooling
Feed cue data into a review dashboard, translation-QA tool, or automated subtitle-quality check.
Frequently Asked Questions
Can I convert the JSON output back to TTML?
Not with this tool: JSON export is one-directional. It's meant for feeding cue data into scripts, custom players, or review tooling, not as a round-trippable subtitle format. Keep your original TTML/DFXP/ITT file if you need it back.
Does this also work with .dfxp and .itt files?
Yes: .dfxp (SMPTE-TT, common in broadcast workflows) and .itt (iTunes Timed Text) both use the same TTML XML schema, so you can drop either extension into this page and get the same JSON structure.
What happens to TTML's styling and region markup in the JSON?
It's stripped. TTML's tts: styling attributes and region/layout elements have no equivalent in JSON, so only the plain cue text is written to each object's text field.
Tips for Converting TTML to JSON
JSON export is one-way: there is no JSON-to-TTML converter, since JSON here is a data-interchange format for scripts and pipelines, not a subtitle format any player reads back.
Use the startMs/endMs fields for any programmatic timing math (duration checks, overlap detection), they avoid re-parsing TTML's XML clock-time syntax.
If you need the original TTML/DFXP/ITT markup back after working with the JSON data, keep your source file, this export is additive, not a replacement workflow.
Related tools
-
Subtitle to JSON Converter
Convert any subtitle file to JSON online, free, private, and entirely in your browser.
-
SMI to JSON Converter
Convert SMI subtitles to JSON instantly in your browser.
-
TTML to VTT Converter
Convert TTML subtitles to VTT instantly in your browser.
-
SUB to JSON Converter
Convert SUB subtitles to JSON instantly in your browser.