CSV input
Paste your CSV below, then press Convert.
PHP Array output
Waiting for CSV input.
Convert CSV to PHP Array free, in seconds. Paste your data below, press Convert, then copy the result and paste it into your PHP config or seeder. Everything runs in your browser, so nothing is ever uploaded.
Paste your CSV below, then press Convert.
Waiting for CSV input.
Paste CSV into the input box and press Convert (or just keep typing, conversion happens as you type). The tool parses it with the PapaParse library, using the first row as column headers, then emits modern PHP short array syntax wrapped in a
The output uses modern short array syntax with 'key' => value pairs and is wrapped in <?php return [...]; so the file works the moment you save it as a .php file. Strings are single-quoted, numbers stay numeric, booleans become true or false, and missing values become null. Paste it straight into a Laravel config file, a Symfony parameter file or a database seeder.