---
title: "Text Comparison - AllTools"
description: 使用最长公共子序列（LCS）算法逐行比对两段文本，准确识别新增行与删除行，适用于代码与文档版本校对。粘贴即可处理，结果能直接复制，全程在本地运行。
canonical_url: "https://tool.warmday.wang/en/text/diff"
meta:
  author: AllTools
  keywords: "online tools, AllTools, free online tools, developer tools, image tools, PDF tools, text tools, unit converter, no login, browser-based tools"
  "og:description": 使用最长公共子序列（LCS）算法逐行比对两段文本，准确识别新增行与删除行，适用于代码与文档版本校对。粘贴即可处理，结果能直接复制，全程在本地运行。
  "og:image": "https://tool.warmday.wang/img/og-cover.png"
  "og:image:alt": "AllTools Logo"
  "og:image:height": "630"
  "og:image:width": "1200"
  "og:title": "Text Comparison"
  "twitter:image": "https://tool.warmday.wang/img/og-cover.png"
---

> Index of every page on this site: [llms.txt](https://tool.warmday.wang/llms.txt)

# **Text Comparison**

Line-level text differences comparison based on the LCS algorithm, highlighting new and deleted lines.

## **Original Text**

## **Modified Text**

## **Compare Settings**

**Case-insensitive**

**Ignore first and last whitespace in rows**

**Ignore empty rows**

### **Instructions**

#### **Introduction**

Use the Longest Common Subsequence (LCS) algorithm to compare two pieces of text line by line to accurately identify new and deleted lines, which is suitable for code and document version proofreading.

#### **Steps**

Paste the original text to the left, paste the modified text to the right, check the ignore option as needed, and click Compare to see the difference results.

#### **Notes**

This tool is a line-level comparison and does not subdivide character differences in lines; for character-level highlighting, use the Text Difference Enhancement tool. Oversized text contrast can be time-consuming.

## **Related tools**

More from the same category · Text Processing

[**Kaomoji Collection**Cute kaomoji ready to copy](https://tool.warmday.wang/en/text/kaomoji) [**Word Count**Count Chinese characters, words and characters](https://tool.warmday.wang/en/text/count) [**Text Deduplication**Remove duplicate lines, keep first occurrence](https://tool.warmday.wang/en/text/deduplicate) [**Text Sorter**Sort lines ascending, descending, natural or random](https://tool.warmday.wang/en/text/sort) [**Find and Replace**Find and replace with regex support](https://tool.warmday.wang/en/text/find-replace) [**Case Converter**UPPER, lower, Title, Camel, Snake, Kebab and Constant case](https://tool.warmday.wang/en/text/case-converter)

```json
{"@context":"https://schema.org","@graph":[{"@type":"Organization","@id":"https://tool.warmday.wang/#organization","name":"AllTools","alternateName":"AllTools - 全能工具箱","url":"https://tool.warmday.wang/","logo":{"@type":"ImageObject","url":"https://tool.warmday.wang/img/logo.png","width":512,"height":512}},{"@type":"WebSite","@id":"https://tool.warmday.wang/en#website","url":"https://tool.warmday.wang/en","name":"AllTools","inLanguage":"en","publisher":{"@id":"https://tool.warmday.wang/#organization"},"potentialAction":{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https://tool.warmday.wang/en?q={search_term_string}"},"query-input":"required name=search_term_string"}},{"@type":"WebPage","@id":"https://tool.warmday.wang/en/text/diff#webpage","url":"https://tool.warmday.wang/en/text/diff","isPartOf":{"@id":"https://tool.warmday.wang/en#website"},"inLanguage":"en","name":"Text Comparison","description":"使用最长公共子序列（LCS）算法逐行比对两段文本，准确识别新增行与删除行，适用于代码与文档版本校对。粘贴即可处理，结果能直接复制，全程在本地运行。"},{"@type":"SoftwareApplication","@id":"https://tool.warmday.wang/en/text/diff#app","name":"Text Comparison","description":"使用最长公共子序列（LCS）算法逐行比对两段文本，准确识别新增行与删除行，适用于代码与文档版本校对。粘贴即可处理，结果能直接复制，全程在本地运行。","url":"https://tool.warmday.wang/en/text/diff","applicationCategory":"UtilitiesApplication","operatingSystem":"Web","inLanguage":"en","isPartOf":{"@id":"https://tool.warmday.wang/en/text/diff#webpage"},"offers":{"@type":"Offer","price":"0","priceCurrency":"CNY"}},{"@type":"BreadcrumbList","@id":"https://tool.warmday.wang/en/text/diff#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https://tool.warmday.wang/en"},{"@type":"ListItem","position":2,"name":"Text Tools","item":"https://tool.warmday.wang/en/text"},{"@type":"ListItem","position":3,"name":"Text Diff","item":"https://tool.warmday.wang/en/text/diff"}]}]}
```

## Sitemap

See the full [sitemap](https://tool.warmday.wang/sitemap.md) for all pages.
