URL Encode/Decode API
Percent-encode and decode URLs and query strings online. Component and full-URL modes, full unicode support, 100% client-side and free.
The URL Encode/Decode is also available as a free REST API. Send a POST request with a JSON body to https://dot.tools/api/tools/url-encode — no authentication, no API key, CORS enabled. Successful calls return { "ok": true, "result": { … } }; failures return HTTP 400 or 422 with an error body.
Request body
| Field | Type | Required | Description |
|---|---|---|---|
mode | "encode" | "decode" | required | Whether to percent-encode or percent-decode the input. |
scope | "component" | "full" | required | component encodes/decodes every reserved character (like encodeURIComponent); full preserves URL structure characters like / : ? & = # (like encodeURI). |
input | string | required | The text to encode, or the percent-encoded string to decode. |
Response
| Field | Type | Required | Description |
|---|---|---|---|
output | string | required | The percent-encoded or decoded result. |
Example request
curl -X POST https://dot.tools/api/tools/url-encode \
-H 'Content-Type: application/json' \
-d '{
"mode": "encode",
"scope": "component",
"input": "café & crème brûlée 🍮 — 100% délicieux"
}'Sample response
{
"ok": true,
"result": {
"output": "caf%C3%A9%20%26%20cr%C3%A8me%20br%C3%BBl%C3%A9e%20%F0%9F%8D%AE%20%E2%80%94%20100%25%20d%C3%A9licieux"
}
}Use the free URL Encode/Decode in your browser, read the URL Encode/Decode guide, or import the full OpenAPI specification.