CSV SQL Workbench
Run SQL queries on CSV files in your browser. Check column types, combine tables and download your results.
How can I query CSV files with SQL in my browser?
Import a CSV, choose its delimiter and blank-cell handling, and review the inferred column types before adding the table. Load up to six tables, inspect their schemas and run read-only SQLite queries with optional bound parameters. Filter, aggregate or join the data, inspect full cell values and export CSV or typed JSON results. Files remain on your device.
A closer look, on your device
Open the data. Find the answer.
No database open
Import a data file or load the fictional sample tables.
Files stay on this device. Closing the page clears imported tables. Keep your original CSV/JSON files and download your query notebook; the notebook excludes datasets.
A few tables. A useful answer.
Choose CSV or a JSON array of records. Review names and types before adding data. Your files stay on this device.
Up to six tables with 20,000 rows and 50 columns each. Table names use letters, digits and underscores, starting with a letter or underscore. Numbers with leading zeroes stay TEXT. REAL uses floating point; use TEXT for exact decimals. JSON objects and arrays remain JSON text for json_extract().
Inside the database
Tables, views and relationships will appear here when you open a database.
A question for your data
One SELECT, WITH or EXPLAIN query. ⌘/Ctrl + Enter runs it. Database-changing commands are disabled.
Named parameters
For WHERE city = :city, use {":city":"Toronto"}. Values may be text, a finite number or null. Quote integers outside JavaScript’s safe range.
Saved queries (0/30)
Three simple steps
How to use CSV SQL Workbench
Load the sample tables or choose a local CSV or JSON file, then review column types before adding it.
Inspect your tables and write a read-only query, or select keys in the join builder.
Inspect the result and download CSV or typed JSON. Save a query notebook to reuse the SQL with your original files.
Common questions
Good to know
Understand the result.
Keep the original.
Is this tool free, and are my files uploaded?
This tool is free with no account required. The work happens in your browser. Your input and files are not sent to a processing server.
What are the limits and details?
Uses the SQLite dialect, with parsing and queries in disposable local workers. Up to six tables, 20,000 rows and 50 columns each; four million imported characters per file and eight million combined table characters. Query outputs show at most 5,000 rows and 100 columns. SQLite has a 64 MiB heap limit and jobs stop after 12 seconds. INTEGER keeps signed 64-bit values; REAL uses binary floating point. Quote large JSON integers and keep exact decimals as TEXT. Nested JSON is stored as JSON text; mixed primitive columns become TEXT. Data and queries are not saved automatically; downloaded query notebooks exclude datasets.