CSV to JSON Converter
Batch convert CSV or TSV to JSON or NDJSON, with support for multiple parsing and output options.
Browser execution mode: Your data is processed in your browser and is not uploaded to the server.
Speed and Stability: Processing speed depends on your device and browser. For large batch work, the desktop version may be more stable.
Loading tool, please wait...
Loading tool, please wait...
If the online tool fails to load or run, try the desktop tool.https://tools.yikeaigc.com/
Tool Usage
Return to old version
i
Set parsing options before converting.Supports CSV, TSV, TXT, and batch files. Only the first 20 files are shown, but all files are processed.
CSV/TSV to JSON
NDJSON output
Column mapping & type inference
Settings can be saved
Choose CSV data source
Select CSV, TSV, or TXT files in batch, or paste CSV text to convert.
Files are processed on this page and are not uploaded to a server.
Parsing, output, and mapping settings
Click “Auto-detect” first to get the delimiter and preview, then adjust output options for the target JSON structure.
Parse settings
Auto-detect first, then fine-tune manually.
Output settings
Object arrays fit API data; NDJSON fits logs and line-by-line imports.
Filter and rename columns
Enter column names or indexes. Index starts at 0.
Only these columns will be output if set.
Applies only when Keep columns is empty.
Data preview
Preview the first rows after importing data.
Data rows0
Columns0
Delimiter-
Source-
Convert, Preview & Download
Convert first to generate results. Copy or download a single result, or download multiple files as a ZIP.
Status
Waiting to convert.
Check settings, then click “Start Convert”.
Result generated
You can download the converted JSON file.
Result preview
Preview only the first 120KB of the first result.
转换后将在这里显示JSON预览。
Tips
Adjust delimiter, encoding, or header settings as prompted.
Instructions
Software Usage Instructions
- Select a data source: Upload CSV, TSV, or TXT files, or paste CSV text directly; for batch files, only the first 20 are shown for review, but all files will be processed during conversion.
- Set parsing parameters: First select or automatically detect the delimiter, then set the encoding, text qualifier, header row, empty row handling, leading/trailing whitespace handling, and comment line prefix based on your data.
- Set the output structure: Choose an array of objects, an array of arrays, or an array of key-value pairs; output formats support standard JSON and NDJSON, and you can set the indentation style.
- Configure field handling: Adjust the key name style, enable type inference, convert empty strings to null, generate nested objects by dot notation, and enter rules for keeping columns, excluding columns, and renaming fields.
- Preview data: After entering parameter settings, view the parsing results, number of data rows, number of columns, and source information. Confirm that the fields are not misaligned before converting.
- Start conversion: Click “Start Conversion”, and the tool will generate JSON or NDJSON results based on the current parameters.
- Download results: A single result can be downloaded directly; multiple files will be output using their original file names, duplicate names will be automatically numbered, and they can be packaged as a ZIP for download.
FAQ
A: An array of objects uses the header row as field names, making it suitable for API data and business data organization; an array of arrays keeps only the values in each row, with a more compact structure, making it suitable for data processing scenarios where the field order is fixed.
A: NDJSON is a format with one JSON value per line, suitable for logs, batch imports, stream processing, and line-by-line data reading tasks. If you need to process data line by line, choose NDJSON output.
A: After enabling “Generate nested objects by dot notation”, headers such as user.name and user.email will be converted into a structure like {"user":{"name":"...","email":"..."}}, which is suitable for organizing multi-level fields such as users, orders, and products.
A: When “Type Inference” is enabled, the tool converts numbers, true, false, null, and date formats to their corresponding JSON types. If you need to keep the original strings, you can turn off type inference.
A: “Keep Only Columns” and “Exclude Columns” support entering column names or indexes, with multiple values separated by commas; for “Column Renaming,” enter one rule per line, for example user.name=user.fullName.
A: By default, the original file name is retained and the extension is replaced with json or ndjson. If multiple files have duplicate names, the tool automatically appends a number to later file names to avoid overwriting results.