PHP → JSON
Supported input includes simple array structures with [] or array(), => keys, strings, numbers, true, false and null.
Development
Convert simple PHP array structures to JSON examples or create PHP array code from JSON. Processing happens locally in the browser and no PHP code is executed.
Supported input includes simple array structures with [] or array(), => keys, strings, numbers, true, false and null.
Valid JSON is converted into PHP array syntax. Objects become associative arrays and JSON arrays become numeric arrays.
Constants, function calls, variables, classes, special comment logic and PHP expressions are not executed. This is intentional and keeps the tool safer for examples.