Can I compare private text without sending it to an online diff service?
Yes. A JavaScript difference algorithm can compare the two strings in the browser and return runs that were added, removed or unchanged. The private Dhrub Free Tools workspace uses jsdiff and applies character, edit-distance and elapsed-time limits so unusually large or dissimilar inputs stop instead of consuming unbounded work.
How to use the tool
Paste both versions
Place the earlier text on the left and the revised text on the right.
Choose line or word mode
Use lines for documents or code blocks, and words for a closer prose comparison.
Read the highlighted result
Added content appears separately from removed content; copy the revised text only after checking it.
At a glance
- Comparison engine
- jsdiff
- Modes
- Line and word
- Server upload
- None
- Difficult comparison timeout
- Approximately 250 milliseconds
Line mode and word mode answer different questions
Line comparison is useful when line breaks carry meaning, such as source code, addresses, lists or paragraph-oriented drafts. Replacing one word on a line can make the old line appear removed and the new line appear added.
Word comparison tokenises more finely and is often easier to read for ordinary prose. It requires more work for large, highly dissimilar texts, so the private tool uses a smaller total-character limit in word mode.
- Use line mode to see structural edits.
- Use word mode to inspect phrasing changes.
- Remember that a difference algorithm does not judge meaning or truth.
- Review punctuation and whitespace when exact formatting matters.
Privacy does not replace document controls
Local processing means the pasted versions are not submitted to the guide site or an application API. The operating system, browser, clipboard manager, extensions and any screen-sharing software remain part of the user’s own environment.
A visual diff is not a legal redline, authorship record or version-control history. For contracts, policies and regulated documents, retain the authoritative files and use the review process required by the organisation.
Important limitations
- The tool compares text characters and tokens; it does not compare document formatting, comments or tracked-change metadata.
- Large or computationally difficult comparisons stop at published limits.
- Unicode segmentation and language-specific word boundaries can vary by algorithm and language.
- A highlighted change does not establish authorship, intent, accuracy or legal effect.
Questions people ask
Why does one changed sentence show as two changed lines?
Line mode treats a whole line as its basic unit. Switch to word mode to see smaller changes within the sentence.
Why did the comparison stop?
The combined input exceeded the selected mode’s character limit, or the algorithm reached its time or edit-distance bound. Compare smaller sections instead.
Does the tool save my versions?
The tool does not submit them to an application server. Refreshing or closing the page clears the working state unless the browser itself preserves the page.
Primary and project sources
- jsdiff project — jsdiff maintainersPrimary documentation for the text difference engine, modes and abort limits.
- String comparison and collation — Unicode ConsortiumBackground on why text comparison and language-sensitive ordering are not always simple byte operations.
- DOM text content — WHATWGBrowser standard for representing output as text rather than interpreted markup.