텍스트 비교

Text Compare (Diff)

두 텍스트를 입력하고 ‘비교’를 누르세요. Enter two texts and press Compare.

텍스트 비교란?

텍스트 비교(diff)는 두 텍스트를 줄 단위로 맞대어, 어느 줄이 추가되고 삭제되었는지 색으로 강조해 보여 주는 도구입니다. 문서의 이전 버전과 새 버전을 붙여넣으면 바뀐 부분을 한눈에 확인할 수 있어, 계약서·기획서 대조나 코드 변경 확인에 유용합니다.

사용 방법

왼쪽 원본 텍스트에 이전 버전을, 오른쪽 비교 텍스트에 새 버전을 붙여넣고 ‘비교’를 누르세요. 결과 카드에 줄별로 녹색(+)=추가, 빨강(−)=삭제, 무색=그대로가 표시됩니다. 모든 처리는 브라우저 안에서만 이루어져 서버로 전송되지 않습니다.

비교 원리 (줄 단위 LCS)

두 텍스트를 줄바꿈 기준으로 나눈 뒤, LCS(최장 공통 부분수열) 동적계획법으로 두 목록의 공통 줄을 최대한 맞춥니다.

  • 공통 줄 — 양쪽에 그대로 있는 줄 (무색)
  • 삭제 줄 — 원본에만 있는 줄 (− 빨강)
  • 추가 줄 — 비교 텍스트에만 있는 줄 (+ 녹색)
참고: 줄 단위 비교이므로 같은 줄 안에서의 부분 수정은 그 줄 전체가 삭제+추가로 표시됩니다.
개인정보·큰 텍스트
  • 서버 전송 없음: 입력한 텍스트는 저장·전송되지 않고 브라우저에서만 처리됩니다.
  • 큰 텍스트: 각 입력이 수천 줄 이내면 원활합니다. 매우 큰 텍스트(각 5,000줄 초과)는 비교를 제한하니, 문단·장 단위로 나눠 비교하세요.
What is text compare?

The text compare (diff) tool lines up two texts line by line and highlights which lines were added or removed. Paste an old and a new version to see the changes at a glance — handy for reviewing document edits or code changes.

How to use it

Paste the previous version into Original text and the new version into Text to compare, then press Compare. Each line is shown as green (+) = added, red (−) = removed, or unmarked = unchanged. Everything runs in your browser — nothing is sent to any server.

How it works (line-based LCS)

Both texts are split by line break, then a Longest Common Subsequence dynamic-programming pass aligns as many common lines as possible.

  • Common lines — present in both (unmarked)
  • Removed lines — only in the original (− red)
  • Added lines — only in the compared text (+ green)
Note: Comparison is line-based, so an edit within a line shows that whole line as removed plus added.
Privacy & large text
  • No upload: your text is never stored or sent — it stays in your browser.
  • Large text: a few thousand lines per box work smoothly. Very large inputs (over 5,000 lines each) are limited, so split by section.
텍스트 비교(diff)는 어디에 쓰나요?
문서의 두 버전을 붙여넣어 어느 줄이 바뀌었는지 확인할 때 유용합니다. 계약서·기획서 수정본 대조, 코드 변경 확인, 번역 전후 비교, 이메일 초안 검토 등 '무엇이 달라졌는지'를 빠르게 파악해야 하는 모든 상황에 쓸 수 있습니다.
줄 단위 비교는 어떤 원리인가요?
두 텍스트를 줄바꿈 기준으로 나눈 뒤, LCS(최장 공통 부분수열) 동적계획법으로 두 목록의 공통 줄을 최대한 맞춥니다. 원본에만 있는 줄은 삭제(−, 빨강), 비교 텍스트에만 있는 줄은 추가(+, 녹색), 양쪽에 공통인 줄은 그대로 표시합니다.
입력한 텍스트가 서버로 전송되나요?
아니요. 모든 비교는 사용자의 브라우저 안에서만 이루어지며, 입력한 텍스트는 서버로 전송되거나 저장되지 않습니다. 계약서·소스코드 등 민감한 내용도 안심하고 붙여넣어 비교할 수 있습니다.
아주 큰 텍스트도 비교할 수 있나요?
각 입력이 수천 줄 이내면 원활하게 비교됩니다. 줄 단위 LCS는 두 텍스트의 줄 수를 곱한 만큼 계산량이 늘어나므로, 매우 큰 파일(각 5,000줄 초과)은 브라우저 부담을 막기 위해 비교를 제한하고 안내를 표시합니다. 그럴 때는 문단·장 단위로 나눠 비교하세요.
어떻게 활용하면 좋나요?
왼쪽(원본)에 이전 버전을, 오른쪽(비교 텍스트)에 새 버전을 붙여넣고 '비교'를 누르면 됩니다. 녹색은 새로 추가된 줄, 빨강은 삭제된 줄, 무색은 그대로인 줄입니다. 요약에 표시되는 추가·삭제 줄 수로 변경 규모를 한눈에 확인할 수 있습니다.
What is text compare (diff) for?
Paste two versions of a document to see which lines changed. It's useful for comparing contract or spec revisions, checking code changes, reviewing translations, and any case where you need to spot what changed quickly.
How does line-based comparison work?
Both texts are split by line break, then a Longest Common Subsequence (LCS) dynamic-programming pass aligns as many common lines as possible. Lines only in the original are marked removed (−, red), lines only in the compared text are added (+, green), and shared lines are shown as-is.
Is my text sent to a server?
No. All comparison runs in your browser; your text is never uploaded or stored, so you can safely paste sensitive content such as contracts or source code.
Can it compare very large texts?
A few thousand lines per box compare smoothly. Line-based LCS scales with the product of the two line counts, so very large files (over 5,000 lines each) are limited to protect the browser, with a notice shown. Split by paragraph or section in that case.
How should I use it?
Paste the previous version on the left (original) and the new version on the right, then press Compare. Green lines were added, red lines were removed, unmarked lines are unchanged. The summary's added/removed line counts show the size of the change.

안내: 본 도구는 텍스트를 줄 단위로 비교하며, 모든 처리는 브라우저 안에서만 이루어져 입력값이 서버로 전송되지 않습니다. 매우 큰 텍스트는 비교가 제한될 수 있습니다.

Note: This tool compares text line by line, entirely in your browser — your input is never sent to a server. Very large texts may be limited.