Skip to main content
SubtitleMatrix

TXT to ASS

Format conversionPlain text transcript
Or paste subtitle text

Options

Used when the source has no end times (plain text, LRC). The timeline in the output is generated here rather than converted, so this number is what you get.

What this conversion changes

2 things are dropped or need a decision

  • Timing

    the timeline itself — the source records no timings, so the output's is generated rather than converted

  • Precision

    timing precision — the output's clock is coarser, so every timestamp is rounded to the nearest 10 ms

This list comes from the capability matrix for these two formats, not from the particular file you loaded. A specific file may lose more if it uses features the format allows but the matrix does not model.

This page converts TXT to ASS. Drop a file in — or paste the text — and you get the ASS version back. The conversion runs entirely in your browser, so nothing is uploaded and no account is needed.

These two formats do not store the same things, and the difference is not cosmetic: timing and precision have nowhere to go in ASS. The list above comes from what the two formats can each express rather than from your file, so it is the same answer before you load anything.

One file is fine, and so is a whole season: the queue works through them in order and the results come down together as a single ZIP.

Examples

A typical TXT file, converted to ASS

Input

The quick brown fox jumps over the lazy dog.

Second paragraph, first line.
Second paragraph, second line.

Output

[Script Info]
ScriptType: v4.00+

[V4+ Styles]
Format: Name, Fontname, Fontsize, PrimaryColour, SecondaryColour, OutlineColour, BackColour, Bold, Italic, Underline, StrikeOut, ScaleX, ScaleY, Spacing, Angle, BorderStyle, Outline, Shadow, Alignment, MarginL, MarginR, MarginV, Encoding
Style: Default,Arial,20,&H00FFFFFF,&H000000FF,&H00000000,&H00000000,0,0,0,0,100,100,0,0,1,2,2,2,10,10,10,1

[Events]
Format: Layer, Start, End, Style, Name, MarginL, MarginR, MarginV, Effect, Text
Dialogue: 0,0:00:00.00,0:00:02.00,Default,,0,0,0,,The quick brown fox jumps over the lazy dog.
Dialogue: 0,0:00:02.00,0:00:04.00,Default,,0,0,0,,Second paragraph, first line.
Dialogue: 0,0:00:04.00,0:00:06.00,Default,,0,0,0,,Second paragraph, second line.

Dropped in this output: timing and precision. Everything else matches line for line.

The same conversion on an awkward input

Input


Hello world.

Second block.

Output

[Script Info]
ScriptType: v4.00+

[V4+ Styles]
Format: Name, Fontname, Fontsize, PrimaryColour, SecondaryColour, OutlineColour, BackColour, Bold, Italic, Underline, StrikeOut, ScaleX, ScaleY, Spacing, Angle, BorderStyle, Outline, Shadow, Alignment, MarginL, MarginR, MarginV, Encoding
Style: Default,Arial,20,&H00FFFFFF,&H000000FF,&H00000000,&H00000000,0,0,0,0,100,100,0,0,1,2,2,2,10,10,10,1

[Events]
Format: Layer, Start, End, Style, Name, MarginL, MarginR, MarginV, Effect, Text
Dialogue: 0,0:00:00.00,0:00:02.00,Default,,0,0,0,,Hello world.
Dialogue: 0,0:00:02.00,0:00:04.00,Default,,0,0,0,,Second block.

This is the kind of damage real files have — mixed line endings, stray whitespace, fields left empty. Compare it with the tidy example above to see what the parser forgives.

Frequently asked questions

Are the timecodes invented when a TXT file becomes ASS?

Yes, and it is worth saying plainly: a TXT file has no timings at all, so the timeline in the ASS output is laid out here rather than converted. The first line starts at zero and each line after it starts where the previous one ended, so the spacing is even and the order is yours. The duration field on this page decides how wide each slot is.

Why have the timestamps moved from TXT to ASS?

TXT has no timecodes to move — the timeline in this conversion is laid out here — and ASS stores time as `0:00:04.13`, a hundredth of a second. So the generated slots are rounded to the nearest 10 ms as they are written. Nothing is reordered, and no line moves by more than 5 ms from where this page put it.

What does the output look like when TXT becomes ASS?

Like ASS: no cue numbers: every subtitle is a `Dialogue:` line in the `[Events]` section, with a layer field where SRT keeps the number. Every TXT cue becomes one ASS cue, in the same order, with the same text.

Do TXT cues keep their order in the ASS output?

Yes, and they are sorted by start time on the way — earliest first, which is how every format here expects them and how players read them. If your TXT file listed its cues out of sequence, the ASS output puts them back in order; that is a change to the file's structure rather than its content, and it is deliberate.

Can I convert the ASS back to TXT?

Yes, and it has its own list: converting ASS to TXT drops timing, styling, positioning, karaoke, line breaks and format-specific content. That list is different from the one above because the two formats keep different things.

Does the ASS output keep the TXT file's encoding?

No — the output is UTF-8, with Unix line endings and no byte-order mark, whatever the TXT file used. A file that arrives in UTF-16, or in a Windows single-byte encoding, is decoded on the way in (the result panel says so when that happens); what comes out is always the same UTF-8 ASS.

Related tools