Text Transform

Turn a list of lines into a comma- or custom-delimited string and back, with trim, dedupe, sort and quoting along the way.

Runs entirely in your browser — nothing is sent to our servers.

Presets:

How to use it
  1. Pick a direction: Lines → List to join, or List → Lines to split a delimited string.
  2. Set the separator — defaults to a comma and space.
  3. For Lines → List, optionally wrap each item in quotes, add a per-item prefix or suffix, and/or wrap the whole output (e.g. [ / ] for a JSON array).
  4. Toggle trim, remove-empty, dedupe and sort as needed.
  5. Copy the result from the output panel.

Defaults to a comma and a space — the trailing space won't show visually.

Quote each item

Line cleanup

Sort

Input (one item per line)

Output (delimited list)

apple, banana, apple, cherry

What is text transform?

A recurring chore when moving data between tools: a spreadsheet column or a pasted list of names needs to become a SQL IN (...) clause, a comma-separated CLI argument, or a JSON array of strings — and later the reverse, turning a delimited blob back into one item per line for a spreadsheet paste.

This tool handles both directions, plus the cleanup that usually comes with it: trimming stray whitespace, dropping blank lines, removing duplicates, and sorting — before joining with any separator, optional quoting, an optional prefix or suffix per item, and an optional wrapper around the whole joined output.

Why use this tool

Doing this by hand in a text editor means several passes of find-and-replace and manual dedupe — trim trailing spaces, delete blank lines one at a time, eyeball the list for duplicates, then wrap each line in quotes before joining. This tool applies every option live as you type, so you can see the result update and copy it the moment it looks right — entirely in your browser, so a pasted list of internal usernames or account IDs never leaves the page.

A few concrete shapes this covers: pasting a spreadsheet column of IDs and turning it into a SQL IN ('id1', 'id2', 'id3') clause with single-quote wrapping and a comma separator; turning a list of feature flags into a JSON-style array by quoting each item with double quotes and setting [ / ] as the whole-output wrapper; or collapsing a multi-line list of file paths into a single space-separated string for a shell command that takes several arguments. The reverse direction is just as common — a comma-separated value pulled from a config file or an API response, split back into one item per line to paste into a spreadsheet or review one at a time.

Dedupe and sort behavior

Dedupe is case-sensitive

Dedupe compares exact string equality after trimming (if trim is on), and it is case-sensitive — Apple and apple are treated as different items and both survive deduping. If a list is coming from inconsistent manual entry and needs case-insensitive deduping, lowercase everything first with a find-and-replace or another tool, then dedupe here.

Sort is natural, not lexicographic

Sorting is locale-aware with numeric awareness, meaning it does a natural sort rather than a strict character-by-character one — item2 sorts before item10, where a naive lexicographic sort would put item10 first because the character 1 comes before 2. This matters most for lists that mix words and numbers, like version strings or numbered test cases.

Text transform FAQ

No. All splitting, joining and cleanup happens locally in your browser.

Yes — set the separator to ", ", quote to double quotes, and copy the result straight into IN (...).

Yes, any string works, including things like " | " or a tab character.

Exact string equality after trimming (if trim is on) — case-sensitive.

Locale-aware alphabetical sorting with numeric awareness, so item2 sorts before item10.