About this tool
Paste two versions of any text or code and see a line-by-line comparison with added lines in green and removed lines in red, computed with a longest-common-subsequence algorithm. Perfect for spotting edits without a heavyweight tool.
Both texts are split into lines and compared exactly, so a change in capitalisation, a trailing space or a different indent makes a line count as changed. A line that was edited appears as one removed line followed by one added line. The summary beside the button shows how many lines were added and removed.
Because the comparison builds a table with one cell for each pair of lines, memory use grows with the product of the two line counts. Files of a few thousand lines compare quickly, while files of tens of thousands of lines may be slow or fail on a small device.