URL encode JSON

URL Encode JSON instantly converts JSON to a URL-safe format. Clean, fast encoding you can copy, export, or preview live in-browser.

Paste your input above or import a file below.
No file chosen
Supported file types: .txt, .csv, .tsv, .log, .json, .xml, .md, .ini, .yaml, .yml, .html, .htm, .css
Total characters: 0

How to Use:

Paste your JSON into the input box or import it from a file. As soon as you do, the tool encodes it using encodeURIComponent and shows the result in the output box. If your JSON is valid, you’ll get a compact, URL-safe string you can use in query parameters or web requests. You’ll also see a live character count. Use “Copy Output” to grab it, “Export to File” to save it, or “Clear All” to start fresh.

What URL Encode JSON can do:

URL Encode JSON is perfect when you need to shove JSON into a URL like embedding filters, sending config data, or preloading state. It takes valid JSON and safely escapes everything that would break in a query string. You get instant feedback, no guesswork. And if something’s wrong? It tells you exactly what’s invalid so you can fix it fast. It all happens right in your browser, with no server involved.

Example:

Input:

{ "name": "Alice & Bob", "age": 30, "city": "New York" }

Output:

%7B%22name%22%3A%22Alice%20%26%20Bob%22%2C%22age%22%3A30%2C%22city%22%3A%22New%20York%22%7D

Common Use Cases:

Use URL Encode JSON when building links that pass JSON data, working with GET-based APIs, or storing JSON in URLs for preview or sharing. It’s also handy for testing encoded payloads or checking how special characters are escaped. No bloat, no fluff just a fast, clean way to make your JSON safe for URLs.

Useful Tools & Suggestions:

Before encoding, Escape JSON should be used to clean up any risky characters that might break the format. After it’s encoded, Convert JSON to a Data URI can be handy if you’re planning to embed it directly in a link or script.