Transform - Encoding

Free URL Decode API Endpoint

The free URL decode API endpoint turns percent-encoding back into text and answers JSON. A + stays a +, since it means a space only in HTML form bodies, and a broken escape is refused rather than passed on.

  • No API key
  • JSON answer
  • Strict escapes
  • UTF-8

Decode percent-encoding

POST/url_decode

https://aisenseapi.com/services/v1/url_decode

Call the free URL decode API endpoint

curl -X POST https://aisenseapi.com/services/v1/url_decode \
  -H "Content-Type: application/json" \
  -d '{"data": "a%20b%2Fc+%C3%A9"}'
{"url_decoded_data":"a b/c+é"}

The other way is the URL encode API endpoint.

Rules

  • Every % has to be followed by two hex digits. A literal % is written %25.
  • A + is left as it is. A query string from an HTML form writes a space as +; replace those before decoding.
  • The decoded bytes have to be UTF-8 text, since the answer is JSON. For binary data use the hex or Base64 decoder.

Send the data as {"data": "..."} with Content-Type: application/json, or as the raw request body with any other content type. The raw body takes binary data as it is: curl --data-binary @file.bin -H "Content-Type: application/octet-stream".

Errors

StatuserrorWhen
400No data to decode.No data string and no body
400Invalid percent-encoding.A % without two hex digits after it
400The decoded bytes are not UTF-8 text.Escapes that decode to bytes that are not text
413Data over 1 MiB.More than 1 MiB in one request

Each refusal also carries fix, a sentence saying what to send instead.

Common uses

Read a logged URL

Turn a path or query value from an access log back into the text a client sent.

Check an encoder

Decode what another library produced and compare it with what went in.

Agents reading links

Give an agent the readable form of a link before it reasons about it.

Privacy and limits

Nothing is stored. The URL decode answer is worked out while the request is open and the data is gone with it. The access log records the path and the status, not the body.

The base URL is https://aisenseapi.com/services/v1. There is no key, no account and no sign-up step. One request carries at most 1 MiB of data, and the service-wide limit is 5000 requests per IP address per day. Every endpoint in the collection is listed on the Free public REST APIs reference, and the encodings side by side on Encoding APIs.