JavaScript Object to JSON Converter

Convert loose JS object literals (unquoted keys, single quotes, trailing commas) into valid JSON.

About this tool

Evaluates the literal in your own browser only (nothing is sent anywhere) and prints strict JSON. Only paste data you trust, since the input is run as JavaScript. Functions and undefined values are dropped by JSON.

Related: JSON Formatter & Validator · Base64 Encode & Decode · URL Encoder & Decoder · SHA-256 / SHA-1 Hash Generator · Unix Timestamp Converter