Skip to content
Jellykit

Remove Empty Lines

Delete blank lines, including ones that only hold spaces or tabs, and keep every line that has text on it.

  • Runs on your device
Loading tool

About Remove Empty Lines

Copying from emails, web pages and word processors leaves gaps between lines. This deletes every line that is empty or holds nothing but spaces and tabs, and tells you how many it removed.

Lines with text are left untouched, spacing and order included, and the line endings of your text are kept.

How it works

  1. The text is split into lines at any kind of line break, and the ending used in the input is used again in the output.
  2. Clean-ups run in this order: non-printing characters, trimming, collapsing spaces, empty lines, duplicates, and finally the line order.
  3. Duplicates are compared after the earlier steps, keeping the first occurrence. Accented letters typed in different ways count as the same.
  4. Sorting uses your browser language rules, so accented letters sort next to their base letter. Shuffling uses the browser secure random generator.

Questions

Is a line with only spaces counted as empty?

Yes. Spaces, tabs and other blank Unicode characters do not count as content, so such lines are removed too.

Can I keep one blank line between paragraphs?

Not with this option, which removes all of them. Use find and replace with a regular expression if you need to reduce several blank lines to one.

Everything you enter here is processed in this browser tab. Nothing is uploaded, logged or shared. How privacy works here.