JSON to PHP Array
Convert JSON objects to PHP array syntax β short array notation, properly escaped, copy-paste ready.
Runs locally in your browser. Your input is not uploaded.
How to Use
- 1
Paste your JSON
Paste any JSON object or array into the input panel.
- 2
Copy the PHP array
The equivalent PHP short-array assignment appears instantly in the output panel.
- 3
Use it in your code
Paste into your PHP source β config files, fixtures, or seed data β with no further editing.
Frequently Asked Questions
- Modern short array syntax ([...]) with string keys quoted using single quotes and proper escaping. The output is a complete $data = [...]; assignment you can paste into any PHP file.
Related Tools
JSON FormatterFormat, validate, and minify JSON with syntax highlightingJSON DiffCompare two JSON objects side-by-side and highlight differencesJSON to CSVExport JSON arrays to CSV with nested object flatteningCSV to JSONParse CSV files into structured JSON arraysJSON to XMLConvert JSON objects to XML with pretty-print outputXML to JSONParse XML and convert to clean JSONJSON to YAMLConvert between JSON and YAML formats bidirectionallyQuery String to JSONParse URL query parameters into JSON with nested support