JSON to SQL
Turn a JSON object or array of objects into SQL INSERT statements. Set a table name, copy the query, and keep rows on the device instead of pasting fixtures into a hosted converter.
Runs in your browser. Nothing is uploaded.
0 characters · 0 lines
0 characters · 0 lines
About this tool
Turn a JSON object or array of objects into SQL INSERT statements. Column names are the union of object keys. Strings are quoted, booleans become TRUE/FALSE, null becomes NULL, and nested objects are stored as JSON text.
How to use: paste [{"id":1,"name":"Ada"}], set a table name, copy the INSERT. A single object is treated as one row. Keys that are not safe identifiers are rewritten. This is fixture SQL, not a migration tool.
Example: two user objects become INSERT INTO "users" ("id", "name") VALUES (1, 'Ada'), (2, 'Grace'); Identifiers use ANSI double quotes.
Rows stay on the device. Related: JSON to CSV if you needed a spreadsheet instead, SQL formatter to re-indent the result. After load, converting works offline.
FAQ
Related Convert tools
JSON ↔ YAML
Convert JSON to YAML and YAML back to JSON in the browser. Paste a config, Kubernetes snippet, or API fixture and copy the other format. Parsing uses js-yaml locally. Documents are never posted to a converter.
JSON ↔ TOML
Convert JSON objects to TOML and TOML documents back to JSON in the browser. Handy for Cargo.toml, pyproject, and app config fragments. Parsing stays on-device.
JSON ↔ XML
Convert JSON objects to XML and XML documents back to JSON. Useful for SOAP leftovers, RSS, and mixed API stacks. XML is parsed with the browser DOMParser so payloads stay on the device.
JSON ↔ CSV
Turn an array of JSON objects into CSV, or parse CSV headers into JSON objects. Quote-aware parsing runs in the tab so spreadsheets of IDs and emails are not uploaded to a conversion service.
CSV ↔ TSV
Convert comma-separated values to tab-separated values and back, preserving quoted fields. A small delimiter swap for dumps you would rather not paste into a spreadsheet SaaS.
Timestamp Converter
Convert Unix timestamps, milliseconds, and ISO 8601 dates in both directions. See UTC and local time side by side, generate a 'now' epoch, and copy values for logs, databases, and APIs without a round trip to a conversion API.