Skip to main content

How to Validate a CSV File and Fix Common Problems

Nothing uploadedTested up to 200 MB

Check a CSV for broken rows, headers, quotes, separators, encoding problems, and other issues before you import it. Your file stays on your device.

Published: 2026-08-28Updated: 2026-09-084 minValidate your CSV
Data workflow illustration for How to Validate a CSV File and Fix Common Problems

A CSV can open in a spreadsheet and still contain problems that break an import. One row may have too many columns. A quote may never close. Two columns may have the same name. Some text may already be damaged.

The CSV validator checks the whole file and tells you where those problems are, without changing the original CSV.

What the validator checks

Some problems are likely to break an import or put values in the wrong columns:

  • a row has more or fewer columns than the header,
  • a quoted value never closes,
  • a column name is empty,
  • the same column name appears more than once,
  • a damaged replacement character appears in the text,
  • a quote is used in a place where it was not properly escaped.

Other problems may still import, but they are worth reviewing:

  • the file mixes different kinds of line breaks,
  • one row appears to use a different separator from the rest,
  • the file is not clean UTF-8 text,
  • the separator is unclear because more than one choice looks possible,
  • the same column mixes quoted and unquoted values in an inconsistent way.

The report can also point out smaller cleanup issues:

  • a marker appears at the start of the file that some programs handle differently,
  • a value has extra spaces at the beginning or end,
  • a row is completely empty.

How to validate a CSV

  1. 01

    Add your CSV

    Choose one CSV. The file stays on your device; the tool page shows the current file-size limit.

  2. 02

    Run the check

    The tool reads the file from start to finish and looks for CSV structure problems.

  3. 03

    Start with the errors

    Fix problems that can break the file shape first, such as wrong column counts, broken quotes, or duplicate headers.

  4. 04

    Review warnings and cleanup items

    Then look at separators, text encoding, line breaks, extra spaces, and empty rows.

  5. 05

    Run the validator again

    After you repair the source or create a cleaned copy, check it again before importing.

How to fix what you find

ProblemWhat to try
A row has too many or too few columnsCheck the source row for an extra separator or missing value. If you need a repaired copy, use the CSV cleaner.
Quotes are broken or used incorrectlyCorrect the export or source data if possible. Otherwise clean the CSV and check it again.
A header is empty or repeatedGive every column a clear, unique name before importing.
Characters look damaged or the file is not clean UTF-8Start from the original export when possible and use the encoding repair tool.
Separators, line breaks, spaces, or empty rows are inconsistentUse the CSV cleaner, then validate the cleaned file again.

If the problem came from an export system, fixing the source is usually better than repairing the same CSV every time. Re-export after the source is corrected, then validate the new file.

How to read the result

Start with the most serious findings. These are the ones most likely to stop an import or shift data into the wrong columns.

Warnings deserve a look, especially when the destination is strict about separators, text encoding, or line endings. Smaller cleanup items may not block an import, but they can still cause matching or row-count problems later.

The detailed list shows up to 1,000 findings. If your file contains more problems than that, fix the ones shown first and run the validator again. This keeps the repair process manageable instead of giving you an endless list all at once.

What happens to your file?

The CSV is processed on your device. It is not uploaded to our servers.

The validator is read-only. It does not replace, rewrite, or save over your original file.

If you want a corrected CSV, use the CSV cleaner or the encoding repair guide, then validate the result again.

Practical limits

The validator accepts one CSV up to 200 MB. The cap follows the same registry method: the displayed limit comes from the shipped tool registry and is backed by first-party browser measurement. The first-party measurement evidence is recorded in docs/tool-audit/batch-a.md.

The file size is not the only thing that matters. Ordinary rows can be handled efficiently even in a large file, while one unusually wide record needs much more working memory at once. A file made of normal-sized rows can therefore be much easier to validate than a same-size file dominated by one huge record.

The detailed findings list shows up to 1,000 problems at a time.

The validator checks CSV structure. It does not know the rules of the system you plan to import into. A file can pass this check and still fail later because a required column is missing, a date is in the wrong format, or a value is outside an allowed range.

Simple example

Suppose the header has four columns, but one row has five because a note contains an extra separator that was not handled correctly.

The validator points you to that row. You can fix the source, export again, and rerun the check.

After: every row has the same number of columns, so the importer is much less likely to shift data into the wrong place.

For checks a validator cannot know — required destination fields, accepted values, date formats, or import rules — use the pre-import CSV checklist.

A U.S.-formatted value is not a structural error

customer_id,state,amount,invoice_date
00125,CA,1234.50,12/31/2026

The decimal point and U.S.-style date do not make this CSV invalid. A structural error would be something like an extra unquoted comma that gives one row five fields while the header has four. Whether the destination wants 2026-12-31 is a separate import rule.

Validate your CSV

See the transformation

Structural problems become a precise review queue

See the exact rows with formatting problems while leaving the original file unchanged.

Input
ordercustomertotal
1041ana@…149.90
1042marc@…
1043“lina@…86.50
Result
Row 42· ragged row
Row 87· unclosed quote