Line ending converter
Detect CRLF, LF and CR line endings with counts and convert a whole text to one consistent style.
Related tools
Line ending converter
Every operating system family ends lines its own way: Unix and modern macOS use LF, Windows uses CRLF, and classic Mac OS used a bare CR. Paste any text and the converter reports exactly what it found — how many CRLF, LF and CR endings, and whether the file is consistent or mixed — then rewrites every ending to the style you choose. The tally reads like a receipt: 14 CRLF + 2 LF → 16 LF, so you can see at a glance what changed.
Mixed endings are the classic invisible bug. A file edited on Windows and Linux in turn stops matching in diffs, git flags every line as changed, shell scripts fail with cryptic errors like "bad interpreter: /bin/bash^M", and CSV imports gain phantom blank rows. Because the difference is invisible in most editors, the fastest fix is exactly this: paste, convert to LF (or CRLF for Windows tooling), copy back.
Two extra options finish the cleanup in one pass. "Ensure single trailing newline" makes the text end with exactly one newline — the POSIX convention that linters and code reviews keep asking for — and "Strip trailing whitespace on each line" removes the spaces and tabs that hide at line ends and pollute diffs. Both are off by default, so the tool changes nothing you did not ask for.
Your text is processed entirely in your browser and never uploaded anywhere. Convert scripts, config files and source code safely, then copy the result or download it as a .txt file.