Convert SRT to JSON
Convert subtitles to a clean JSON array with millisecond timings and readable timecodes. For players, pipelines and scripts. Runs in your browser.
Anything that processes subtitles in code wants them as data, not as a text format with a parser attached: a custom web player, a search index over dialogue, a script that aligns two translations, an LLM pipeline that needs the transcript with timing intact. This converter emits a plain JSON array — one object per cue, indexed from one, with both millisecond fields for arithmetic and formatted timecodes for reading a diff.
Worth knowing
- Each object carries startMs and endMs as integers plus start and end as SRT-style timecodes, so neither a script nor a human has to convert anything to work with the file.
- Line breaks inside a cue are kept as \n inside the text string rather than split into an array, which keeps the shape stable whether a cue has one line or three.
- Reading JSON back in is deliberately forgiving: a bare array or an object with a cues, subtitles or events key all work, as do times given in milliseconds, as fractional seconds, or as timecode strings.
- Cues with no usable timing are skipped rather than failing the whole file, so a hand-edited or partially populated export still imports.
FAQ
What exactly does the JSON look like?
An array of objects, each with index, startMs, endMs, start, end and text — for example {"index":1,"startMs":1000,"endMs":3000,"start":"00:00:01,000","end":"00:00:03,000","text":"Hello"}. Convert a short file to see the real shape before writing code against it.
Can I convert JSON back into SRT or VTT?
Yes — drop the JSON file in and pick any target format. That makes JSON a practical intermediate step for a script: export to JSON, transform the text or timings in code, then convert the result back to whatever your player needs.