Markdown diff compares two documents as lines. A list item you rewrote is one removed line and one added line, and the heading above it stays, marked with a leading space in the patch. The left column shows the original with removals struck through. The right column shows the revision with the new lines. Compare with holds the second document, or you choose a second file.
The diff does not understand Markdown structure. A paragraph rewrapped to a different line length looks like a large edit even when the words are the same, because the line breaks moved. A changed heading is a changed line. Use this page for notes, lists, and docs. Use JSON diff when the file is JSON and key order should not count.
Original: # Stock - Pen Compare with: # Stock - Pencil
@@ -1,3 +1,3 @@ # Stock -- Pen +- Pencil The heading and the blank line stayed. - Pen is marked removed. - Pencil is marked added. The leading hyphen of the list item is part of the line, separate from the patch's minus and plus.
List items and headings are lines, so the patch points at the bullet you changed and leaves the heading unmarked when it stayed.
The whole line. - Pen is removed and - Pencil is added. The heading # Stock carries a leading space in the patch, meaning it was in both documents.
The comparison is line by line. New line breaks are edits even when the sentences match. Keep a stable wrap if you want the patch to show wording changes.
Each original line is marked removed. A one-line note such as Odd socks in the dryer. with an empty revision is a single deletion hunk.
It diffs the source lines. It does not compare the formatted preview. A bold marker that moved is a text change.
Text diff is the same line comparison for plain text. This page is the one aimed at Markdown files, and it accepts a Markdown or text file.