# CSV cleaner

> Clean CSV and Excel files online: trim spaces, remove blank rows and columns, fix garbled accents, headers, names, emails, numbers and dates. Free, private.

Canonical: https://cromagnon.app/tools/csv-cleaner
Last updated: 2026-10-26

- Category: Clean
- Formats: CSV · TSV · XLSX · XLS
- Use it: https://cromagnon.app/tools/csv-cleaner (free, runs in the browser)

## What it does

Clean a messy CSV or Excel file in one pass, and see every change before you download it. The cleaner trims and collapses spaces, removes invisible characters such as zero-width and non-breaking spaces, repairs garbled accents (Ã© back to é), blanks out placeholders like N/A, handles line breaks inside cells, removes blank rows, empty columns and exact duplicates, and makes headers unique in the style you need. Column fixes then tidy whole columns: names to Title Case, emails to lower case, phones to digits, amounts like Rs 1,250 to plain numbers and dates in mixed formats to YYYY-MM-DD.

## How to use it

1. Drop a CSV, TSV or Excel file, paste rows from a spreadsheet, or try the sample.
2. Check the Found line: it lists the problems in the file before anything changes.
3. Turn the cell clean-up, row and header options on or off; each shows how many cells it changed.
4. Choose a column fix for columns that need one, such as Title Case for names or Date for a date column.
5. Review the preview: changed cells are green and cells a fix couldn't read are red. Switch to Original to compare.
6. Download the cleaned file as CSV, TSV or Excel.

Tip: Clean before you remove duplicates or join files. ali khan, Ali Khan and Ali  Khan only match once spaces and case are fixed.

## The problems it fixes

- **Extra spaces**: Spaces at the start or end of a cell, or two spaces in a row, break lookups, filters and duplicate checks while being nearly invisible.
- **Invisible characters**: Zero-width spaces, byte-order marks, soft hyphens and non-breaking spaces copied from web pages and PDFs. They make identical-looking values different.
- **Garbled accents**: Text saved as UTF-8 and opened as Windows-1252 turns é into Ã© and ’ into â€™. The cleaner turns them back, and leaves correct accents alone.
- **Placeholders**: N/A, null, none, -, #N/A and NaN mean empty. Blanking them stops them being counted, summed or imported as text.
- **Line breaks in cells**: Multi-line notes can break imports into older systems. Replace them with spaces or remove them.
- **Blank rows and empty columns**: Left over from exports and copy-pasting. They're removed; a column only counts as empty when every cell is.

## Column fixes

Pick a fix in the list next to each column name. Title Case capitalises names correctly, keeping small words such as of and the lower case and handling names like McDonald and O'Neil. Email removes spaces and mailto: and lowers the case. Phone keeps the digits and a leading + for international numbers. Yes / No turns y, true, 1 and similar into Yes and No.

Plain number strips currency symbols and codes (Rs, PKR, $, €, £), thousands separators and spaces, reads (120) as -120, and understands both 1,234.56 and 1.234,56. Date reads 03/04/2024, 3 Apr 2024, 2024-04-03 and other layouts and writes them all as 2024-04-03, the format every database and spreadsheet understands. It works out whether the column puts the day or the month first from values such as 25/03, which can only be day first. Cells a fix can't read are left unchanged and shown in red so you can correct them by hand.

## Headers for databases and code

Duplicate or blank headers stop imports, so the cleaner always makes them unique (Email, Email 2). snake_case (customer_name) is the safest choice for SQL databases and data tools, camelCase (customerName) suits JavaScript and JSON, and Title Case reads best in reports.

## Saving for Excel and other software

Download as CSV, TSV or a real Excel workbook. For CSV choose the separator your software expects (a semicolon for Excel in much of Europe), and keep the UTF-8 BOM ticked if the file will be opened in Excel, so accents and non-Latin letters show correctly. Formula protection puts an apostrophe in front of cells that start with =, +, - or @, which stops spreadsheets running them as formulas: a sensible default for data that came from a web form.

## Tips

- **Fix the encoding first**: If the whole file is garbled, choose the right encoding in the bar above the preview before cleaning.
- **Choose the sheet**: For Excel files with several sheets, pick the sheet in the bar above the preview.
- **Keep the original**: The tool never changes your file; it downloads a new one, so you can always start again.
- **Then deduplicate**: For duplicates that differ in case, accents or typos, take the cleaned file to the duplicate remover.
- **Pasted from a website?**: Tables copied from web pages are full of non-breaking spaces and hidden characters. Keep Remove invisible characters on, then check the Found line to see how many there were.
- **Dates in two formats**: When one export mixes 03/04/2024 and 2024-04-03, apply the Date fix to the column and look for red cells: those are the values that need a human decision.

## Questions

### What does the CSV cleaner fix?

Spaces, invisible characters, garbled accents, placeholders, line breaks in cells, blank rows, empty columns, exact duplicates and headers, plus column fixes for case, emails, phones, numbers, Yes/No and dates.

### Does it work with Excel files?

Yes. XLSX, XLS, ODS and Numbers files open with a choice of sheet, and you can download the result as Excel or CSV.

### Can I see what changed?

Yes. Changed cells are highlighted, each option shows its count, and there's a list of example changes and a view of the original.

### Will it change correct accents?

No. Only character sequences that are valid garbled UTF-8 are repaired; é, ñ and ü that are already right stay as they are.

### How large a file can it clean?

Up to 150 MB, depending on your device's memory. Hundreds of thousands of rows are fine on a normal computer.

### Is my file uploaded?

No. Files are opened and processed in your browser, on your device. Nothing is uploaded, stored or logged, so the tools are safe for private and work files.

## Related

- [Duplicate Remover](https://cromagnon.app/tools/duplicate-remover)
- [Encoding Fixer](https://cromagnon.app/tools/encoding-fixer)
- [Column Analyzer](https://cromagnon.app/tools/column-analyzer)
- [Delimiter Converter](https://cromagnon.app/tools/delimiter-converter)
- [CSV to JSON](https://cromagnon.app/tools/csv-to-json)
- [All tools](https://cromagnon.app/tools)
