Free MySQL export tool — no upload, no account

Convert MySQL to CSV
Dump files or
CLI output.

Free MySQL to CSV converter. Upload a mysqldump .sql file to extract INSERT data, or paste MySQL CLI query output — pipe-table or tab-separated. Handles backtick quoting and MySQL escape sequences. Runs in your browser.

Your data never leaves your browser
mysqldump parser
CLI output parser
Copy to clipboard
Always free
MySQL to CSV Converter  100% client-side
Drop your mysqldump .sql file here
INSERT statements with backtick identifiers parsed automatically
Paste MySQL CLI query output
 Export complete

      
Native MySQL CSV export commands

Use these commands when you have direct database access — faster than this tool for large datasets.

SELECT INTO OUTFILE — fastest, requires server access
SELECT * FROM `your_table` INTO OUTFILE '/tmp/export.csv' FIELDS TERMINATED BY ',' OPTIONALLY ENCLOSED BY '"' LINES TERMINATED BY '\n';
Requires FILE privilege. The path must be writable by the MySQL server process. Check with: SHOW VARIABLES LIKE 'secure_file_priv';
mysql CLI — tab-separated output, no server file access needed
mysql -u username -p database_name \ -e "SELECT * FROM your_table" \ | sed 's/\t/,/g' > export.csv
Outputs tab-separated values. The sed command converts tabs to commas. Or paste the raw output here and CSVShift handles the conversion.
mysqldump — export table as INSERT statements
mysqldump -u username -p database_name \ your_table \ --no-create-info \ --complete-insert \ > table_dump.sql
Use --no-create-info to skip the CREATE TABLE statement. Upload the resulting .sql file above to convert INSERT statements to CSV.
How MySQL to CSV conversion works

Two parsers for two common MySQL data formats.

1
MySQL Dump mode

Uploads a .sql file from mysqldump and parses every INSERT INTO block. Handles MySQL-specific syntax: backtick-quoted column names, INSERT IGNORE, multi-row VALUES with thousands of rows per statement, and MySQL escape sequences (\', \\n, \\t).

2
MySQL CLI Output mode

Accepts the output pasted from the mysql terminal — the pipe-table format with +----+-------+ borders and | id | name | rows. Also accepts tab-separated output from mysql -e "SELECT...". Border rows and "N rows in set" footers are stripped automatically.

3
Download RFC 4180 CSV

The output is proper RFC 4180 CSV with UTF-8 BOM encoding — fields containing commas or newlines are correctly quoted. Open directly in Excel, Google Sheets or import into any database or ETL tool.

When do you need MySQL to CSV conversion?

Common situations where exporting MySQL data to CSV is necessary.

Analysing mysqldump backups

Database backups from mysqldump contain INSERT statements. Converting them to CSV lets you analyse the data in Excel or Google Sheets — or verify backup integrity — without needing a running MySQL instance to restore to.

Database migration

When migrating from MySQL to PostgreSQL, SQLite or another system, exporting to CSV is often simpler than converting the SQL dump directly, avoiding syntax differences between dialects. Convert to CSV first, then re-import using the target system's native CSV loader.

Reporting and data analysis

Business analysts who need MySQL query results in Excel for pivot tables, charts or manual review paste CLI output or upload dump files to convert to CSV without needing direct database access or spreadsheet software plugins.

Sharing data without database access

Developers who need to share a data snapshot with a non-technical colleague or external party export a table as mysqldump, convert to CSV here, and send the spreadsheet — no database credentials required on the receiving end.

Related CSV tools

Other free converters on CSVShift you might need.

Popular searches
mysql to csv converter export mysql to csv mysql copy to csv convert mysql to csv mysqldump to csv converter convert mysqldump to csv export mysql table to csv mysql query to csv dump mysql table to csv export mysql database to csv mysql export to csv command line mysql save to csv

MySQL data parsed
in your browser. No upload.

CSVShift parses mysqldump files and MySQL CLI output entirely in JavaScript in your browser. Your database data — which may contain sensitive business or personal records — is never transmitted to any server. Both parsers run locally, in memory, on your device.

The MySQL dump parser correctly handles MySQL's backslash escape sequences — \' → ', \\n → newline, \\t → tab — which differ from standard SQL quoting and cause errors in generic SQL parsers.

MySQL escape sequence handling
Correctly decodes \', \\n, \\t and other MySQL-specific escape sequences that generic SQL parsers misread.
Pipe-table auto-detection
Detects the mysql CLI pipe-table format automatically and strips border rows and "N rows in set" footers.
Multi-row INSERT support
Handles mysqldump's batch INSERT format with thousands of value tuples per statement — no row limit.
Free, no conditions
No file size cap, no watermark, no account. Funded by display advertising only.
Frequently asked questions
Common questions about exporting MySQL data to CSV format.
How do I export MySQL data to CSV?
Three methods: 1) SELECT * FROM table INTO OUTFILE '/tmp/file.csv' in MySQL — fastest but requires FILE privilege. 2) mysql -u user -p db -e "SELECT * FROM table" > output.csv from command line. 3) Upload a mysqldump .sql file or paste CLI output here for browser-based conversion.
How do I convert a mysqldump to CSV?
Upload your mysqldump .sql file in MySQL Dump mode. CSVShift parses every INSERT INTO statement — including multi-row batch inserts — extracts backtick-quoted column names, decodes MySQL escape sequences, and downloads a CSV. Works for single-table and multi-table dump files.
How do I export a MySQL table to CSV from the command line?
Run: mysql -u username -p database -e "SELECT * FROM table" | sed 's/\t/,/g' > output.csv. Or paste the raw mysql CLI output (with the +---+ borders) into CSVShift's CLI Output mode — it strips the borders and converts to proper CSV automatically.
How do I convert MySQL query results to CSV with headers?
Run your query in the mysql CLI — the first row of the output is always the column headers. Paste the output into CSVShift's CLI Output mode and select "First row is column headers". The headers will appear as the first row in the downloaded CSV.
Is my database data safe when converting MySQL to CSV online?
Yes. CSVShift processes everything in your browser. Your mysqldump file and any pasted query output are never uploaded or transmitted. Open the Network inspector during conversion — zero outbound data requests are made.