All Tools
Categories
XML Tools 64 Email Marketing Tools 55 Import-Export Tools 50 JSON Tools 36 Text Tools 12 Shipping Freight Tools 5 Calculator 4 Marketing Tools 3
About Contact Privacy

JSON to Form Data

Generate HTTP form data from a JSON object in one click: bracket-path nesting, array indices, URL-encoded body or readable key=value lines. All client-side.

JSON Input
Waiting for input
Form Data Output
Use the body with Content-Type: application/x-www-form-urlencoded — for example curl --data "user[name]=Ada&items[0]=a". Nested paths use bracket notation; arrays use indices.

About JSON to Form Data

Every time a browser submits a form, it sends application/x-www-form-urlencoded data: percent-encoded key=value pairs joined with &. When you need to reproduce that body from a JSON object — for an integration test, a curl command or a mock server — doing the encoding by hand is slow and full of edge cases (spaces, &, =, Unicode).

Convert JSON to Form Data flattens a JSON object into valid form encoding with one click. Nested objects become user[name] paths, arrays become items[0] indices, values are URL-encoded, and you can choose between the compact body string and readable key=value lines.

Features

  • Bracket-path nesting: user[name] and items[0][name] forms for nested objects and arrays.
  • URL-encoded output: A ready-to-send application/x-www-form-urlencoded body string.
  • Readable mode: Decoded key=value lines for eyeballing and debugging.
  • Framework-friendly: Express, PHP, Rails and Spring parse the bracket paths back into structures.
  • Typed literals: Numbers, booleans and null become their text form, as form data is always textual.
  • Live preview: Output updates as you type.
  • Copy and download: Grab the body for curl, fetch or Postman instantly.
  • Private: All processing happens in your browser; nothing is uploaded.

How to Use

  1. Paste your JSON object into the input pane.
  2. Pick the output style — the urlencoded body or readable lines.
  3. Copy the body and use it with curl --data, fetch or Postman.
  4. Or download the lines for review.

Examples

Example 1 — curl reproduction. A developer captures a form submission as JSON in devtools, converts it here, and pastes the body into curl --data "user[name]=Ada&port=5432" to reproduce the request from the terminal.

Example 2 — Mock server. An integration team generates expected request bodies for a mock from their JSON fixtures, guaranteeing byte-identical form data for the test run.

Example 3 — Framework debugging. A PHP engineer converts a payload to form lines to confirm how bracket notation maps onto $_POST nesting before writing the handler.

Example 4 — API documentation. A writer includes a form body example in docs, generated from the JSON version so the two never drift apart.

Benefits

  • Correct encoding: Percent-encoding matches browser behavior for every character.
  • Structure preserved: Bracket paths carry nesting and array order.
  • Immediately usable: Paste the body straight into curl, fetch or Postman.
  • Zero data movement: The document is converted locally and never uploaded.
  • Instant results: Live output updates with every keystroke.

Frequently Asked Questions

What is form data?
Form data is the key=value encoding used by HTML forms and HTTP requests with the content type application/x-www-form-urlencoded. Every value is URL-encoded, and pairs are joined with &. Browsers and most HTTP clients accept it directly.
How are nested objects encoded?
Nesting is expressed with bracket notation: {"user":{"name":"Ada"}} becomes user[name]=Ada. Most frameworks — Express, PHP, Rails, Spring — parse bracket paths back into nested structures automatically.
How are arrays encoded?
Array elements get indices: items[0]=a&items[1]=b. That form is unambiguous and widely understood. The same pattern works for arrays of objects: items[0][name]=Ada.
What gets URL-encoded?
Both keys and values are percent-encoded with encodeURIComponent semantics, so spaces, &, =, %, non-ASCII characters and every other byte survive the trip. The readable key=value output shows the decoded form for humans.
Can I test an endpoint with the output?
Yes. The urlencoded string is exactly the request body to send with the header Content-Type: application/x-www-form-urlencoded — usable with curl --data, fetch, Postman and similar tools.
Is my JSON uploaded anywhere?
No. Conversion happens entirely in your browser. Nothing is uploaded, stored or logged.