How to use it
- Paste your JSON into the input box, upload a .json file, or drop a file onto the box.
- The SQL appears as you type.
- Enter your table name and choose the quoting style for your database.
- Copy the result or download it as a .sql file.
Good to know
- Nested objects become dotted column names, so supplier.city gets its own column. Arrays become numbered columns: tags.0, tags.1 and so on. If the data is a list, each entry becomes one row.
- Empty cells become NULL and true/false become TRUE/FALSE. Pick standard double quotes for PostgreSQL and SQLite, backticks for MySQL, or square brackets for SQL Server.
About the formats
JSON
JSON (JavaScript Object Notation) stores data as nested objects and arrays. It is the standard format for web APIs and the config files of most JavaScript projects.
SQL
SQL INSERT statements add rows to a database table. The output is one multi-row INSERT that runs in PostgreSQL, MySQL, MariaDB, SQLite and SQL Server.
Questions
- Is my data uploaded anywhere?
- No. The conversion runs in your browser with JavaScript. Your data never leaves your device, and the tool keeps working if you lose your connection after the page has loaded.
- What happens to nested JSON?
- It is flattened. Each nested value gets a column named after its path, such as supplier.city or tags.0. Empty lists and empty objects become empty cells.