Convert CSV to List
Convert CSV to lists with column-by-name selection, dedupe, sort, prefix/suffix wrap. RFC 4180 compliant. Free, offline, client-side, instant.
Convert CSV/TSV to a list with column selection by header name (not just index), dedupe + sort, and prefix/suffix wrap each item - perfect for SQL IN clauses, email-list extraction, and config seeding.
Output options
How to Use Convert CSV to List
- Paste CSV into the input pane, upload a
.csv/.tsvfile, or click Load sample. - Pick a delimiter (auto-detect works for most files; pick custom for non-standard separators).
- Toggle First row contains headers if your CSV has a header row.
- Choose column selection: all columns (flatten), by index (0-based), or by header name (most readable).
- Pick an output separator (newline for a vertical list, comma for SQL
INclauses). - Optional: add prefix/suffix to wrap each item (e.g.
'...'for SQL strings), deduplicate, and sort. - Copy or download
list.txt.
Frequently Asked Questions
What’s the most common use case?
Extracting an email column from a CSV export, deduplicating, and pasting into a “send to” field. The “by header name” + “deduplicate” + “comma” output separator combination gets you there in 3 clicks. Other common uses: extracting product IDs for a database query, converting addresses to a one-per-line list for printing labels, or scraping a column into a SQL IN ('a','b','c') clause via prefix/suffix wrap.
How do I build a SQL IN clause?
Pick the column you want, set prefix to ', suffix to ', and output separator to comma. Result: 'a','b','c'. Wrap in (...) manually and paste into WHERE id IN (...). The “deduplicate” option saves your database from redundant lookups.
Does it handle quoted fields with internal commas?
Yes – RFC 4180 compliant. "London, UK" stays as one field. Also handles escaped quotes ("" inside a quoted field = literal ") and quoted fields with embedded newlines.
What’s the difference between case-sensitive and case-insensitive dedupe?
Case-sensitive: "USA" and "usa" are KEPT as 2 distinct items. Case-insensitive: they’re merged into one (first occurrence’s case is preserved). Useful when an export has inconsistent casing – say, “Active” / “active” / “ACTIVE” for the same status.
What’s localeCompare for sorting?
The sort uses String.localeCompare – meaning “ä” sorts near “a” (locale-aware), not after “z” as raw character codes would. For predominantly-English data this matches alphabetical expectations. For mixed Unicode (Chinese, Arabic, Cyrillic), the order is locale-correct by browser.
Can I paste TSV (tab-separated)?
Yes. The auto-detect handles tabs. If you paste a table from Excel directly (cells copied to clipboard end up tab-separated), it works as TSV. No quoting needed – tabs almost never appear inside text data.
What if my CSV has different column counts per row?
The parser handles it – each row is parsed independently. When extracting a specific column, rows that don’t have that column are SILENTLY SKIPPED (not errored). For example, extracting column 5 from a CSV where some rows have only 3 columns just gives fewer items than rows.
Why “prefix/suffix wrap” not just CSV escaping?
Because wrap is bidirectional – works for SQL strings ('a','b'), JSON arrays (["a","b"]), Python lists (["a","b"]), bash brace expansion ({a,b}), and bullet lists (- a
- b). CSV escaping is a single-purpose transform; prefix/suffix is general-purpose.
Is my data secure?
Yes. CSV + uploaded files + output stay in your browser via FileReader and clipboard APIs. Nothing is sent to any server.