Comma Separator
Paste one item per line, such as a column copied from a spreadsheet, and get a single comma-separated list. Switch the direction to split a separated list back into lines. You can change the delimiter, wrap items in quotes and drop duplicates. Free, no sign-up, and nothing is uploaded.
Direction
Options
How to Use the Comma Separator
- Choose the direction. Lines to comma-separated joins lines into one string. Comma-separated to lines splits a string into one item per line.
- Set the delimiter. It starts as a comma followed by a space. Change it to a semicolon, a pipe or anything else. For a strict CSV row, use a comma with no space.
- Tick the options. Wrap items in quotes and Remove duplicates apply when you are joining lines, not when you are splitting.
- Paste your list and press Convert. The result does not update as you type. The Items count shows how many came out; then copy the result.
Worked Example
Copying a column from Excel or Google Sheets gives you one value per line. Pasting the four lines apple, banana, cherry and apple (a repeat) gives the results below. Every line is trimmed and empty lines are skipped before anything else happens.
| Options | Output | Items |
|---|---|---|
| Defaults | apple, banana, cherry, apple | 4 |
| Remove duplicates | apple, banana, cherry | 3 |
| Remove duplicates + quotes | "apple", "banana", "cherry" | 3 |
Duplicates are removed first, matched exactly (so "Apple" and "apple" count as different items), and the first occurrence of each stays. Splitting goes the other way: "apple, banana, cherry" with the default delimiter becomes three lines.
A Joiner, Not a CSV Parser
- Quotes follow RFC 4180. Wrapped items get double quotes, and a quote already inside an item is doubled, so 12" ruler becomes "12"" ruler". An item that contains the delimiter or a quote is wrapped even when Wrap items in quotes is off, so a strict CSV reader gets the same items back.
- Splitting understands quoted fields. "Smith, John", "Lee, Ann" gives two items, a doubled quote inside quotes reads as one quote, and a quoted item may hold a line break (it then spans two lines of output). The quotes are removed and spaces inside them are kept. A quote in the middle of an unquoted item, as in 12" ruler, is left alone. For whole rows and columns use CSV to Table.
- The delimiter is used as you type it when joining, spaces included. When splitting, the delimiter itself is trimmed, so ", " splits on a bare comma and the spaces around each item are removed afterwards.
- SQL string lists need single quotes. This tool wraps in double quotes. For
'apple', 'banana'use Add Prefix & Suffix with a single quote in both fields.
Which Tool Do You Need?
| If you want… | Use |
|---|---|
| Lines joined into one list, or a list split into lines | This Comma Separator |
| Text added around every line, with the lines kept apart | Add Prefix & Suffix |
| A list with bullet symbols | Bullet Point Generator |
| Items sorted or de-duplicated as lines first | Sort Lines or Remove Duplicate Lines |
| Real CSV data shown as a table | CSV to Table |
Frequently Asked Questions
- How do I turn a column into a comma-separated list?
- Choose Lines to comma-separated, paste the column with one item per line and press Convert. Each line is trimmed, blank lines are skipped, and the items are joined with your delimiter into one string you can copy.
- Can I use a delimiter other than a comma?
- Yes. The delimiter field takes any text: a semicolon, a pipe, a dash, or a comma followed by a space. The same field is used for splitting a list back into lines. Leave it empty when splitting and the tool falls back to a comma.
- What does Wrap items in quotes do?
- It puts a double quote on each side of every item before joining, so the output looks like "apple", "banana", "cherry". It suits JSON arrays and many programming languages. A quote inside an item is doubled, as the CSV standard requires, and an item that holds the delimiter is wrapped even when this option is off.
- How do I convert a comma-separated list back into lines?
- Choose Comma-separated to lines, paste the list and press Convert. The text is split at the delimiter, the spaces around each item are trimmed, empty pieces are dropped and each item goes on its own line.
- How do I remove duplicates while converting?
- Tick Remove duplicates before pressing Convert. Matching is exact and case-sensitive, and the first occurrence of each item is kept in its original order. The option applies only when you join lines.
- Is my text uploaded or stored?
- No. The conversion runs in your browser and nothing is sent to a server. Closing the tab clears the text.