The Proofreader API allows web pages to check for grammar, spelling, and punctuation errors. It goes beyond returning corrected text by providing structured annotations detailing the error type and plain-language explanations of why the correction was made.

Developer Trial: This API is currently in active development. To use it, you must enable the #proofreader-api flag in chrome://flags. Note that Chrome's current implementation does not yet support the includeCorrectionTypes and includeCorrectionExplanations options — results will omit types and explanation for now.

Proofreader.availability()

Checks if the browser can support proofreading based on the specified requirements, allowing progressive enhancement.

staticavailability(options?: ProofreaderCreateCoreOptions): Promise<Availability>;

Options parameter (ProofreaderCreateCoreOptions)

PropertyTypeDescription
includeCorrectionTypesbooleanIf true, requires the model to label each correction with a CorrectionType: "spelling", "punctuation", "capitalization", "preposition", "missing-words", or "grammar" (the spec draft currently lists a subset without "preposition"/"missing-words"). Defaults to false.
includeCorrectionExplanationsbooleanIf true, requires the model to provide a short plain-language explanation for corrections. Defaults to false.
expectedInputLanguagessequence<DOMString>The expected input language tags (e.g., ['en']).
correctionExplanationLanguageDOMStringThe target language for the explanation text.

Returns

A promise that resolves to an Availability string: 'available', 'downloadable', 'downloading', or 'unavailable'.

Interactive Playground

Proofreader.create()

Instantiates a new Proofreader object, initiating any necessary model downloads.

staticcreate(options?: ProofreaderCreateOptions): Promise<Proofreader>;

Options parameter (ProofreaderCreateOptions)

Inherits all properties from ProofreaderCreateCoreOptions (above) — including includeCorrectionTypes, includeCorrectionExplanations, expectedInputLanguages, and correctionExplanationLanguage — plus:

PropertyTypeDescription
signalAbortSignalAllows aborting the creation and download process.
monitorCreateMonitorCallbackCallback to listen to downloadprogress events.
Interactive Playground

proofreader.proofread()

Proofreads the input string and returns a complete ProofreadResult object containing the corrected string and a detailed array of corrections.

proofread(input: DOMString, options?: ProofreaderProofreadOptions): Promise<ProofreadResult>;

Returns (ProofreadResult)

PropertyTypeDescription
correctedInputDOMStringThe fully corrected string.
correctionssequence<ProofreadCorrection>Detailed list containing startIndex, endIndex, correction, and optional types/explanation (present only when the corresponding include* option was set at creation).

The explainer additionally defines proofreadStreaming(input, options), which returns a ReadableStream that delivers correction explanations as they become available. It is not yet part of the spec draft.

Interactive Playground

proofreader.destroy()

Destroys the proofreader instance, aborting any active requests and allowing the browser to unload the underlying machine learning models from memory.

destroy(): undefined;
Interactive Playground

Properties

PropertyTypeDescription
includeCorrectionTypesboolean (readonly)True if the proofreader provides correction types.
includeCorrectionExplanationsboolean (readonly)True if the proofreader provides explanations.
expectedInputLanguagesFrozenArray<DOMString> | null (readonly)The expected input languages provided during creation.
correctionExplanationLanguageDOMString | null (readonly)The language explanations are generated in, provided during creation.