What Is Word Error Rate?
Word error rate (WER) quantifies how closely a machine-generated transcript matches a reference (ground truth) transcript. It is the most widely used evaluation metric in automatic speech recognition (ASR) and is also applied in machine translation, optical character recognition (OCR), and other text-comparison tasks.
The WER Formula
WER is computed using three types of word-level errors identified through an alignment of the hypothesis transcript against the reference transcript:
Substitutions (S): words that were replaced with a different word.
Insertions (I): words that appear in the hypothesis but not in the reference.
Deletions (D): words present in the reference that are missing from the hypothesis.
The formula is: WER = (S + I + D) / N, where N is the total number of words in the reference transcript. The result is typically expressed as a percentage. Because insertions can add words beyond the reference length, WER can exceed 100% in extreme cases.
How WER Is Calculated Step by Step
Align the hypothesis transcript to the reference transcript using dynamic string alignment (often based on the Levenshtein distance algorithm).
Count the number of substitutions, insertions, and deletions.
Divide the sum of those errors by the total word count of the reference.
Several open-source libraries make this straightforward. In Python, packages such as jiwer provide ready-made functions for computing WER with just a few lines of code.
Interpreting WER: What Counts as "Good"?
What qualifies as a good WER depends heavily on the use case and audio conditions. For clean, read speech (such as audiobook narration), modern ASR systems can achieve WER below 5%. Conversational or noisy audio typically produces higher error rates. Specialized domains like medical or legal transcription often demand very low WER due to the critical nature of the content.
Limitations of WER
While WER is a useful summary metric, it has notable limitations:
It treats all errors equally, whether the error is a minor filler word or a critical proper noun.
It does not account for semantic similarity. Two transcripts with the same meaning but different phrasing can produce a high WER.
Punctuation and capitalization are typically ignored, which may matter for downstream applications.
For these reasons, WER is often used alongside complementary metrics such as character error rate (CER), which measures errors at the character level and can be more informative for languages with complex morphology or for OCR evaluation.
