Fix tabs in JSON strings (no upload)

TL;DR: A JSON string can’t contain a raw tab character. Replace real tabs with \\t, then validate locally (no upload).

Raw tabs can cause invalid control character errors. Escape them safely and validate locally.

Why tabs break JSON

A tab character is U+0009 (a control character). Strict JSON does not allow control characters inside quoted strings unless they are escaped. If you paste JSON that contains a literal tab inside "...", parsers fail with errors like “bad control character” or “invalid character”.

What the broken input looks like

This is invalid JSON if there is a real tab between a and b:

{"cols":"a	b"}

The fix: escape as \\t

Replace the literal tab with the \\t escape sequence:

{"cols":"a\\tb"}

Fast no-upload workflow

  1. Escape/unescape safely with JSON String Escape/Unescape.
  2. Validate the full JSON with JSON Validator.
  3. If the input has comments or trailing commas, normalize with JSON Repair.

Where tabs come from

  • Copying values from spreadsheets or TSV exports.
  • Logs that include formatted columns.
  • Indentation inside quoted strings (accidental).

Trust note: All processing happens locally in your browser. Files are never uploaded.

FAQ

Should I convert tabs to spaces? Only if you want to change the content. Escaping preserves the tab in the parsed value.

What about other invisible characters? Newlines, carriage returns, and other control chars can also break strict JSON. Validate and escape them.

Privacy & Security
All processing happens locally in your browser. Files are never uploaded.