Browser-based transcript alignment · Whisper word times matched onto your own text

Transcript to Audio Aligner

Give the page a recording and the exact words that are spoken in it. It listens with Whisper, matches what it heard to your text, and times every word of your text, then splits the result into SRT and VTT cues.

Recording and transcript

Up to 30 minutes of audio and 5000 words of text.

Drop a recording here or click to choose

.mp3, .wav, .m4a, .ogg, .flac, .mp4

0 words

A good default: noticeably fewer errors than Tiny at about twice the compute. The model downloads once from Hugging Face and is then cached by the browser.

Result

Times appear here once the alignment finishes.

Choose a recording, paste the transcript and press Align the transcript.

Transcript to Audio Aligner

Operator: Abdulla Al Fahad. How tools are built and checked

When the words of a recording are already written down, such as the script of a talk, the minutes of a meeting or an audiobook chapter, the missing piece is when each word is spoken. Speech-to-text is the wrong tool for that on its own, because it rewrites your words with its own mistakes. This page keeps your text and only borrows the times.

It is not forced alignment in the strict sense. A forced aligner such as the Montreal Forced Aligner scores the audio against an acoustic model and a pronunciation dictionary for your exact words, which lets it time a word that was mumbled or run together. Here Whisper first transcribes the audio in your browser, then a global sequence alignment lines its words up against your text. Where the two agree, your word takes Whisper's time. Where Whisper dropped or misheard a word, yours is still timed, placed between the words around it and marked as such.

The output is SRT and WebVTT cues built from your text, not from Whisper's, plus a JSON file with a start, an end, a status and a confidence for every word.

Key features

  • Whisper Tiny, Base or Small in the browser, English-only or multilingual, with a language choice or detection in each 30-second window
  • Needleman-Wunsch matching that tolerates misheard spellings, dropped words and extra words Whisper invented
  • A confidence for each word and for the whole text, and a count of words heard exactly, heard with another spelling, and placed between neighbours
  • Cue splitting by characters per line, lines, longest cue and pause length, rebuilt as you change the settings, with a click-to-play transcript

How the transcript is matched to what Whisper heard

The recording may be audio or video of up to 30 minutes, and the transcript up to 5,000 words (a file of up to 1 MB can be loaded as text). The alignment table, transcript words times recognised words, is capped at 40 million cells: a 5,000-word transcript against up to 8,000 recognised words, well above the roughly 4,500 words of a 30-minute talk at a conversational pace.

Whisper is cut into windows of at most 30 seconds at quiet moments, as in the speech tools on this site. Tiny is roughly 44 MB, Base 80 MB and Small 252 MB on the default CPU path; the one you pick is fetched from Hugging Face on first use and kept in the browser cache.

The words of the transcript are split at spaces and after hyphens, so a hyphenated word can match two spoken words. Punctuation stays attached to the words in the cues but is ignored when matching.

How it works

Both word lists are lower-cased and stripped of punctuation. The aligner scores a table: an exact match earns 3, a close spelling earns 1 plus its similarity, a mismatch costs 2 and a gap in either list costs 1.5. Two words count as close when they are at least three letters long, differ in length by no more than three, and their edit distance is at most half the longer word.

The best path through the table is traced back. Matched pairs give your word Whisper's start and end. A run of your words with no partner is spread between the end of the word before and the start of the word after, in proportion to word length (0.07 s per letter plus 0.1 s, at least 0.12 s a word). If the gap is much longer than that, the words are centred in it at one and a half times their estimated length rather than stretched across silence.

Confidence is 1 for an exact match, the spelling similarity for a close one and 0 for a placed word; the overall figure is the mean over all your words. If fewer than half the words match, a warning suggests the transcript may belong to a different recording.

Cues are built greedily: words are added until the line capacity, the longest-cue time or a pause of 0.7 seconds is reached. A cue also closes at a sentence end once it holds a third of its capacity, and at a comma once it holds four fifths. Each cue is held 0.12 seconds past its last word, up to a minimum of 0.8 seconds, without running into the next one.

Common use cases

  • A 40-minute lecture recorded in two halves, with the lecturer's typed notes as the transcript: align each half separately, since each file may be up to 30 minutes, and join the SRT files with an offset equal to the length of the first.
  • An audiobook chapter of 4,200 words where the narrator ad-libbed three sentences: the extra words Whisper heard are counted as unused, the ad-libs leave gaps, and the chapter's own words stay in order.

How to use this tool

  1. Drop the recording and paste the transcript, or load it from a .txt file.
  2. Choose a model; Base is a good start for clear speech, and pick the language if the recording is not English.
  3. Press Align the transcript and wait for the model download on the first run, then the listening pass.
  4. Read the confidence and the colour of the words: amber ones were not heard, blue ones were heard with another spelling.
  5. Click a few words in the transcript, including amber ones, and listen to check the timing by ear.
  6. Adjust the cue settings until the cues read well, then save SRT, VTT or the word JSON.

Example

Transcript: Thanks for joining us. Today we cover pricing, then the roadmap.

Suppose Whisper returns ten words with times: thanks 0.40-0.72, for, joining, us 1.30-1.50, today 2.10-2.50, we, cover, prizing 2.98-3.46, the 4.30-4.40, roadmap 4.40-5.05. It misheard pricing and missed then.

What the page reports and writes

11 words: 9 heard exactly, 1 heard with another spelling (pricing, similarity 0.86), 1 placed between neighbours (then, 3.59 to 4.17 s). Confidence 90%.
SRT cue 1: 00:00:00,400 --> 00:00:05,170
Thanks for joining us. Today we
cover pricing, then the roadmap.

Common pitfalls

Whisper's word times are estimates taken from the model's attention, and can be off by a few tenths of a second. Expect cue starts to be close, not frame-exact.

If the model build cannot give word times, the page falls back to phrase times and spreads the words inside each phrase evenly; a note beside the result reports the fallback. Cue starts then follow the phrase, not each word.

Numbers and symbols differ in form: a transcript that says 1,000 does not match the spoken words one thousand when Whisper writes them out. Those words land as placed, not heard.

A transcript in a different language from the one set here, or text with a different order of paragraphs from the recording, matches little and produces a low confidence.

  • Paste the transcript as it was spoken, including repeated words and false starts you want kept; text with cuts and tidy-ups matches a smaller share of the audio.
  • If Whisper keeps dropping short words such as articles, a larger model is the lever: the cue settings only change how the words are grouped, not how many are heard.

Common errors and how to fix them

The transcript has 5,200 words; this page aligns up to 5,000
Split the text and the audio by chapter or by section and align each part; the SRT files then need an offset added to the second part.
No speech was recognised, so there is nothing to align to
Whisper returned no words at all. A silent track, a very quiet or noisy recording, or a language setting that does not match the speech can cause it; pick the language by hand and try a larger model.
The transcript (5,000 words) and the 8,500 words heard in the recording together make a table too big to align
The recording contains far more speech than the text, or the reverse. Cut the audio and the transcript at the same chapter break and align each part.
Fewer than half of the transcript words were found in the audio
The transcript may belong to another recording or language. Check the language setting and that the text is in the order it was spoken.

Best practices

  • Run once, read the amber words, and correct the transcript wherever the speaker really said something different; a second run then has fewer gaps to fill.
  • Keep the word JSON next to the SRT; the status field lets you list the placed words and listen to just those moments.

Reading the three word colours

Black words were heard exactly, so their times come straight from the model. Blue words were heard with a different spelling, usually a name or a number, and still take the model's time. Amber words were not heard at all and are timed from their neighbours. A paragraph that is mostly amber almost always means the audio and the text disagree, not that the alignment failed.

Frequently asked questions

When would a true forced aligner give better times?

When you need phoneme-level timing, or the speech is mumbled, whispered or overlapped so that Whisper hears too little to anchor your words. A forced aligner works from your exact text and the sound alone. The trade here is that no pronunciation dictionary is needed, many languages work, and a script that departs from the recording does not break the match.

How is this different from the Auto Subtitle Generator?

The Auto Subtitle Generator on this site writes whatever Whisper heard. This page keeps your text and only borrows Whisper's times, so a misspelt name in the transcript stays as you typed it.

Why does a word Whisper missed still get a time?

Because the words around it were heard. Between two heard words there is a known gap, and a missing word must have been spoken somewhere inside it. The page puts it there and flags it, which is better for subtitles than leaving a hole in the text.

Can I align a song's lyrics?

Rarely well. Whisper's word times are weak under music and singing stretches vowels, so many lyric words come out as placed. Speech, with or without light background sound, is what this is built for.