UUsefulCrate Your files never leave your browser

Home › Tools › Text Cleaner

Text Cleaner

The unglamorous work of tidying a list: strip duplicates, drop empty lines, remove stray whitespace, and sort. Everything happens locally as you work.

100% private — everything runs in your browser, nothing is ever uploaded.

What this tool does

An exported mailing list arrives with the same address three times, blank lines between every entry, and trailing spaces that make a lookup fail. Spreadsheet software can do this, but opening a CSV just to deduplicate a column is a slow detour. This tool takes a plain list with one item per line and lets you strip duplicates, drop empty lines, remove stray whitespace, sort alphabetically, sort numerically or sort by length, and combine those operations in one pass. It is the kind of unglamorous cleanup that sits between an export and whatever comes next: importing contacts, seeding a test database, preparing a word list for a puzzle, or tidying a set of URLs before feeding them into a crawler. The result is plain text, ready to paste back into wherever the data came from.

How to use it in three steps

  1. Paste the list into the box with one item on each line. Blank lines and repeated entries are fine at this stage; the cleanup step will deal with them.
  2. Choose the operations you need. Deduplicate and trim are the usual pair for exports; sorting by length is useful when preparing labels or fixed-width lists.
  3. Press Clean, read the result, and copy it. If the order matters, sort only after deduplicating so you do not lose track of what was removed. Keep the original paste in a second tab so a sorting choice can be reversed without retyping the list.

Questions people ask

Does deduplicate treat capital letters as different?

The comparison is based on the cleaned line, so trimming surrounding whitespace first prevents near-identical entries from surviving as separate items. If case differences matter in your data, review the output before importing it.

Can it handle a CSV with several columns?

It works on lines of plain text. For structured CSV with quoted commas and embedded newlines, use the CSV to JSON converter instead, which parses fields properly rather than splitting on every comma.

Will sorting numerically put 10 after 2?

Numerical sort compares the numeric value rather than the first character, so 2 comes before 10. Alphabetical sort is the mode to use for names, codes and other identifiers where character order is intended.

Can I clean a list that has duplicates differing only by capitalisation?

Trim and deduplicate will collapse entries that differ only in surrounding whitespace, but case differences are separate strings. If your list mixes Product A and product a, normalise the case with the case converter first, then deduplicate here for a clean set.

Privacy: Your list is processed by JavaScript in this browser tab and the cleaned result is shown only to you; no line of it is uploaded, logged or retained after you leave the page.

How to use it

  1. Paste your list, one item per line.
  2. Choose the operation — deduplicate, trim, sort alphabetically, sort numerically, sort by length, or combine them.
  3. Press Clean and copy the result.

Why it stays private

Lists of the kind people clean up here tend to be emails, customer names, phone numbers or keyword sets. Those belong on your machine, not on someone else's server, and with this tool they never leave it.

Questions

Does deduplication keep the original order?

Yes, when you choose Remove duplicates (keep order) the first occurrence of each line is kept in place. The combined Deduplicate + trim + sort option sorts as well, which changes the order deliberately.

Is deduplication case-sensitive?

Yes — "Apple" and "apple" are treated as different lines. If you need case-insensitive matching, normalise the case first.

Can it sort numbers properly?

Yes. Choose Sort numerically and it sorts by numeric value, so 2 comes before 10. Ordinary alphabetical sorting would put 10 before 2.

Related tools

Find & Replace

Bulk find & replace with case, whole-word and regex options.

Text Diff

Paste two versions, see every added and removed line.

Case Converter

camelCase, snake_case, kebab-case and five more, at once.

← All tools