tools/text/text diff
// textnew

text diff

line-level diff between two texts

drag & drop · up to 5 MB (Pro: 100 MB)
— paste two texts to compare // client-only
original
modified
// diff appears here

              curl -sX POST 'https://api.whittly.dev/v1/text/diff' \
  -H 'Authorization: Bearer $WHITTLY_API_KEY' \
  -H 'Content-Type: application/json' \
  -d '{"a":"hello\nworld","b":"hello\nearth"}'
            

              const res = await fetch('https://api.whittly.dev/v1/text/diff', {
  method: 'POST',
  headers: {
    'Authorization': 'Bearer ' + apiKey,
    'Content-Type': 'application/json',
  },
  body: JSON.stringify({ a: "hello\nworld", b: "hello\nearth" }),
});
const data = await res.json();
            

              const { data } = await axios.post(
  'https://api.whittly.dev/v1/text/diff',
  { a: "hello\nworld", b: "hello\nearth" },
  { headers: { Authorization: 'Bearer ' + apiKey } }
);
            
// pro3-way merge viewpro·history syncproupgrade →

// about this tool

A diff compares two texts and identifies which lines were added, removed, or unchanged. This tool performs a line-by-line comparison and highlights changes using the same green/red convention used by Git.

// when to use

  • Compare two versions of a config file
  • Review what changed between two API responses
  • Check your edits before committing to version control
  • Spot unintended changes in generated code

// faq

What algorithm is used?
The comparison uses the Myers diff algorithm — the same algorithm at the core of Git's diff engine. It produces the minimal edit script (fewest insertions and deletions) needed to transform one text into the other.
Is there a size limit?
The tool runs entirely in your browser. Very large inputs (hundreds of thousands of lines) may be slow, but there is no hard limit. No data is uploaded.
// history
Pro Cloud Sync — upgrade
no operations yet