How to validate CSV and TSV files
Paste CSV or TSV text into Paste content or load a CSV, TSV, or TXT file. Validation results show the rules in use, row counts, expected columns, ragged rows, and reported issues. When the issue count is zero, Export CSV/TSV writes the parsed data with the selected output settings.
Use CSV & TSV Validator and Formatter
- Paste CSV or TSV content into Paste content, or choose Drop a CSV or TSV file here and browse files.
- Set Input delimiter to Auto-detect or choose a delimiter that matches the source.
- Choose Quote character, Escape style, and Encoding for the input.
- Set First row is a header, Include header row in export, and Output line endings as needed.
- Review Validation results, correct the source, then select Export CSV/TSV when no issues remain.
How CSV becomes TSV
Choose Comma ( , ) under Input delimiter, then choose Tab (TSV) under Output delimiter. Export changes the separator and applies the selected quote, escape, and line-ending rules. Parsed cell values stay as they are.
Input
name,email,city
Alice,[email protected],London
Output
name email city
Alice [email protected] London
Same as input keeps the delimiter used for parsing. You can also choose comma, semicolon, or pipe. Quote character can be Double quote ( " ) or Single quote ( ' ); Escape style can be Doubled quote ("") or Backslash (\).
Issues reported during validation
Auto-detect compares comma, tab, semicolon, and pipe across the first 25 non-empty lines. Choose a delimiter manually when the source uses another character or those lines do not produce a consistent choice.
The parser reports an unterminated quoted field and a quote inside an unquoted field. Structural checks report inconsistent field counts, duplicate header names, empty header names, and mixed CRLF, LF, or CR line endings. With First row is a header selected, that row sets the expected column count. Without it, the most common data-row length sets the count.
Most issues include a row number. A mixed-line-ending issue applies to the file and shows -. The table lists the first 1,000 issues; Export issues writes the full list to csv-validation-issues.csv.
Preview and export limits
The regular Canonical output preview shows up to 200 data rows. Aligned preview (display only, not exported) displays all parsed rows in padded columns. The aligned view does not change the exported file.
Encoding controls how an uploaded file is read as UTF-8 or Latin-1. Exports use UTF-8. The Custom delimiter field accepts up to three characters, while parsing compares one input character at a time, so enter one delimiter character.
Export remains disabled while issues exist. Parsing, validation, and file generation run in the browser, and the page does not upload the content. The validator reports structure instead of repairing it, so use CSV Cleaner when rows need structural changes. For another spreadsheet check, open Spreadsheet Validate Tools.
Check exports before data handoffs
Check a vendor export before a script reads it. A missing field or an unclosed quote appears in Issues with the affected row.
Turn a comma-separated report into TSV when the receiving system expects tabs. The sample values Alice, [email protected], and London remain unchanged.
Before a data handoff, check duplicate headers and mixed line endings. The issue list gives the source row to correct.
Frequently asked questions
How do I validate a CSV file?
Paste the CSV into Paste content or load it with browse files. Set the parsing rules and review Validation results; parser and structural issues appear before export is enabled.
Can I convert CSV to TSV here?
Yes. Set Output delimiter to Tab (TSV), resolve any reported issues, and select Export CSV/TSV. The downloaded file is named canonical-data.tsv.
Does the CSV validator change cell values?
Cell values pass through as parsed. Export changes delimiter, quoting, escaping, line endings, and whether the header row is included.
Why does my CSV have a ragged row?
A ragged row has a different field count from the expected count. The expected count comes from the header when First row is a header is selected, or from the most common data-row length when it is not.