⚡
usefultools.dev
T⇄J

TSV ↔ JSON Converter

NEW

Convert tab-separated values to a JSON array of objects and JSON back to TSV in your browser, with type detection and escaping.

Runs 100% in your browser — your input is never uploaded or stored on our servers.

Direction
Options

TSV → JSON: with a header row you get an array of objects; without one, an array of arrays. Number detection only converts plain numbers up to 15 digits, so IDs such as 007 or very long numbers stay text. Rows with more values than the header are reported with their line number.

JSON → TSV: the columns are the union of all keys in order of appearance. Nested objects and arrays are written as JSON text. In backslash mode a tab, a line break and a backslash inside a value become \t, \n and \\, and the TSV → JSON direction reverses it.

⚡

Quick Examples

Typical inputs and the results this tool produces.

Minified JSON
name age Ana 31
[{"name":"Ana","age":31}]
Keeps 007
id code 1 007
[{"id":1,"code":"007"}]
Union of keys
[{"a":1,"b":"x"},{"b":"y","c":true}]
a b c 1 x y true
Escaped tab
[["a\tb"]]
a\tb
📖

Overview

The TSV ↔ JSON converter turns tab-separated values into a JSON array and a JSON array back into TSV. TSV is what you get when you copy cells from a spreadsheet or export a table from a database.

Going from TSV to JSON, the first row can become the property names, and numbers, true, false and null can be detected instead of staying text. Going from JSON to TSV, the columns are the union of all keys, nested values are written as JSON text and tabs or line breaks inside a value are escaped as \t and \n, or quoted Excel-style.

Paste text or upload a file, pick the indent, then copy or download the result. The conversion runs in your browser and nothing is sent to a server.

Why use this tool?

  • Turn spreadsheet cells into JSON for APIs and tests
  • Keeps IDs like 007 as text when detecting numbers
  • Handles tabs and line breaks inside values safely
  • Everything stays in your browser
  • Free, no sign-up
⭐

Features

🔄

Both directions

Convert TSV to JSON or JSON to TSV, and use the output as the next input.

🔤

Header row option

Use the first row as property names, or get an array of arrays without a header.

🔢

Type detection

Turn plain numbers, true, false and null into JSON values, or keep everything as strings.

↹

Two escape styles

Backslash escapes (\t, \n, \\) or quoted fields with doubled quotes, as spreadsheets write them.

🧩

Union of keys

JSON objects with different keys still produce one table, with empty cells where a key is missing.

📂

Upload and download

Load a .tsv or .json file, then copy the result or download it with the right extension.

🛠️

How to Use

1

Choose a direction

Select TSV → JSON or JSON → TSV under Direction.

2

Add your data

Paste text, press Upload file, or press Load sample.

3

Adjust the options

Set the header row, type detection, escape style and JSON indent that match your data.

4

Copy or download

Use Copy or Download to take the result, or Use output as input to convert it back.

🤔

Frequently Asked Questions