How to Extract Columns From CSV or Delimited Text
To extract columns from delimited text, paste your data, tell the tool which delimiter separates the columns, list the column numbers you want (counting from 1), and choose an output separator — the selected columns are rebuilt instantly. This guide walks through the process with the free ByteTools Column Extractor, which does it all in your browser with nothing uploaded.
Pulling a single column out of a CSV or reordering a few fields is the kind of task that feels too small for a spreadsheet and too fiddly for a script. The Column Extractor sits neatly in that gap — paste, pick, done.
Step-by-step extraction
- Paste your delimited text with one record per line — a CSV export, a spreadsheet copy or space-separated data.
- Choose the input delimiter: comma, tab, space, or Custom with your own character.
- Enter the column numbers you want, such as
1,3. Columns count from 1, left to right. - Pick the output delimiter — keep the original, or switch to commas, tabs or a custom separator.
- Copy or download the extracted columns from the result box.
A worked example
Say you paste this CSV:
name,email,phone Ada,ada@example.com,555-0100 Grace,grace@example.com,555-0199
Set the input delimiter to comma and enter 2 to grab just the email column. The result is:
email ada@example.com grace@example.com
Want name and phone in that order? Enter 1,3. Want them swapped? Enter 3,1 and the output follows your exact order — extraction and reordering in one step.
Choosing delimiters
| Your data looks like | Input delimiter |
|---|---|
| a,b,c (commas) | Comma |
| a b c (tabs, e.g. spreadsheet paste) | Tab |
| a b c (single spaces) | Space |
| a|b|c or any other symbol | Custom |
The output delimiter is independent of the input, so you can read tab-separated data and emit clean commas — handy for converting a spreadsheet paste into CSV while extracting only the columns you need. If your file uses a semicolon (common in European locales) or a pipe, pick Custom and type that exact character; the tool splits each line on whatever separator you provide.
Handling short or uneven rows
Real exports are rarely perfect — some rows have fewer fields because a value was blank at the end. When you ask for a column that a particular row doesn't have, the Column Extractor fills it with an empty value rather than skipping the row. That single behaviour is what keeps your extracted output aligned line-for-line with the source, so a downstream import or a side-by-side comparison never drifts out of position. It means you can safely extract, say, columns 2,5 from a mixed export and trust that row 100 in the output still corresponds to row 100 of the input.
Why it stays private and fast
Everything runs locally in your browser with JavaScript. Your data is never uploaded, stored or logged, which keeps customer lists, exports and private spreadsheets entirely on your device. Results update live, and because it's a PWA you can use it offline.
Try the Column Extractor — free and 100% in your browser.
FAQ
Do columns count from 0 or 1?
From 1. The leftmost column is column 1, the next is 2, and so on — matching how most people count fields rather than array indexes.
Can I extract more than one column at once?
Yes. List the numbers separated by commas, like 1,3,4. The output includes exactly those columns, in the order you list them.
What if some rows are shorter than others?
Missing columns are treated as empty, so every row stays aligned in the output instead of being skipped. Your extracted data won't drift out of sync.
Does it handle a header row?
It treats every line the same, so your header is extracted alongside the data. If you don't want the header, simply delete that first line before or after extracting.
Related free tools
- Sort Lines — sort the extracted column alphabetically or numerically.
- Remove Duplicate Lines — de-duplicate a list of extracted values.
- Find and Replace Text — tidy the values after extraction.
- Add Line Numbers to Text — number the extracted rows.
Built by ByteVancer
ByteTools is a free product of ByteVancer, a software and web development studio building web apps, SaaS and custom software. If you need custom data tooling or a full product built, explore what ByteVancer can do for you.
Recommended reading
Column Extractor Tips and Common Mistakes to Avoid
Pro tips for extracting CSV columns: pick the right delimiter, avoid off-by-one errors, handle quoted commas, and reorder fields cleanly.
Column Extractor Use Cases: Emails, Exports and More
Real-world column extraction scenarios with examples: pulling emails from exports, reordering fields, building lists and prepping data for import.
XOR Cipher Use Cases: CTFs, Learning, and Puzzles
Real use cases for the XOR cipher, from CTF challenges and teaching bitwise logic to lightweight obfuscation, with concrete worked examples.
XOR Cipher Tips: Keys, Security, and Common Mistakes
Pro tips and common mistakes for the repeating-key XOR cipher: key length, reuse pitfalls, format choices, and when to switch to real encryption.