CSV Linter
Lint and validate CSV data for structural issues like ragged rows and empty lines.
POST
1 credit
/v1/csv-lint
curl -X POST "https://devtools.toolkitapi.io/v1/csv-lint" \
-H "Content-Type: application/json" \
-d '{"csv": "name,age,city\nAlice,30,NYC\nBob,25\nCharlie,35,LA"}'
import httpx
resp = httpx.post(
"https://devtools.toolkitapi.io/v1/csv-lint",
json={"csv": "name,age,city\nAlice,30,NYC\nBob,25\nCharlie,35,LA"},
)
print(resp.json())
const resp = await fetch("https://devtools.toolkitapi.io/v1/csv-lint", {
method: "POST",
headers: {
"Content-Type": "application/json",
},
body: JSON.stringify({"csv": "name,age,city\nAlice,30,NYC\nBob,25\nCharlie,35,LA"}),
});
const data = await resp.json();
console.log(data);
# See curl example
Response
200 OK
{
"valid": false,
"errors": ["Row 3 has 2 columns (expected 3)"],
"warnings": [],
"rows": 4,
"columns": 3,
"inconsistent_rows": [3]
}
Try It Live
Live Demo
Response
Description
Lint and validate CSV data for structural issues like ragged rows and empty lines.
How to Use
1
1. Send a POST request with the `csv` field containing your CSV string.
2
2. Optionally specify a `delimiter` (e.g., `\t` for TSV). If omitted, the delimiter is auto-detected from common candidates (`,`, `\t`, `;`, `|`).
3
3. Check the `valid` field. If `false`, inspect `errors` and `inconsistent_rows` for details.
About This Tool
CSV Linter checks CSV data for structural problems including ragged rows (inconsistent column counts), empty rows, quoting issues, and parse errors. It auto-detects the delimiter if not specified.
Why Use This Tool
- Data import pre-check — Validate CSV files before loading into databases
- ETL pipeline validation — Catch structural issues before data transformation
- Spreadsheet export QA — Verify exported CSVs have consistent column counts
Frequently Asked Questions
How is the delimiter detected?
The linter checks the first line for common delimiters (`,`, tab, `;`, `|`) and uses the first one found. You can override this with the `delimiter` parameter.
Does it validate data types?
No. The linter only checks structural integrity (consistent columns, non-empty rows, parseable CSV). It does not validate data types or content.
Start using CSV Linter now
Get your free API key and make your first request in under a minute.