TSV to JSON Converter

Parses TSV (tab-separated values, with quoting support) and converts each row into a JSON object keyed by the header row, the tab-delimited counterpart to CSV to JSON. A free online tool from Staaarter, right in your browser.

Runs locallyUpdated 2026-07-22

Overview

Introduction

Pasting a range of spreadsheet cells often produces tab-separated text rather than comma-separated, and some data exports use tabs specifically to avoid quoting fields that naturally contain commas. This tool converts that tab-separated data into JSON.

It follows the same header-row-as-keys convention as CSV to JSON, just with tabs as the field delimiter instead of commas.

What Is TSV to JSON Converter?

A TSV-to-JSON converter that treats the first row as column headers and each subsequent row as a record, producing a JSON array of objects.

It supports quoted fields (for tabs, commas, or newlines embedded within a value), the same quoting convention used by CSV.

How TSV to JSON Converter Works

The same character-by-character parser used for CSV to JSON runs here with a tab character as the delimiter instead of a comma, correctly distinguishing delimiter tabs from tabs inside quoted fields.

The first parsed row becomes the object keys; each following row is zipped against those keys into one JSON object per row.

When To Use TSV to JSON Converter

Use it when you've pasted a range of cells from a spreadsheet (which browsers and office suites typically copy as tab-separated text) and need it as JSON.

It's also useful for data exports that specifically use TSV to avoid comma-quoting issues.

Features

Advantages

  • Handles quoted fields correctly, including embedded tabs and newlines.
  • Produces the same clean, uniform JSON array shape as CSV to JSON.
  • Runs entirely client-side.

Limitations

  • All values become strings; no automatic type inference.
  • Assumes a single header row; multi-row headers need manual adjustment first.

Examples

Converting pasted spreadsheet cells

Input

id	name	active
1	Ada Lovelace	true
2	Alan Turing	false

Output

[
  {
    "id": "1",
    "name": "Ada Lovelace",
    "active": "true"
  },
  {
    "id": "2",
    "name": "Alan Turing",
    "active": "false"
  }
]

Tabs separate the fields; the header row becomes the keys for each resulting object.

Best Practices & Notes

Best Practices

  • If your data actually uses commas as the delimiter, use CSV to JSON instead for a more accurate result.
  • Convert string values to numbers or booleans in your own code after this step if you need typed data.
  • Double-check pasted spreadsheet data for stray tabs within cells that weren't quoted at the source.

Developer Notes

This reuses the same RFC 4180-style state-machine parser as CSV to JSON, just invoked with "\t" as the delimiter argument, since the quoting rules for CSV and TSV are functionally identical, only the separator character differs.

TSV to JSON Converter Use Cases

  • Converting spreadsheet cells pasted as tab-separated text into a JSON array
  • Processing a TSV data export for use in a script or test fixture
  • Quickly inspecting tab-delimited data's row and column structure

Common Mistakes

  • Using this on comma-separated data by mistake, which produces a single column per row.
  • Expecting numeric or boolean type conversion; every value stays a string.
  • Not noticing a stray tab inside an unquoted cell, which silently shifts that row's columns.

Tips

  • If a row looks misaligned, check for an unquoted tab character within one of its fields.
  • Pair with JSON to TSV to verify a round trip preserves your data as expected.

References

Frequently Asked Questions