URL Encode / Decode
Encode special characters for safe use in URLs, or decode percent-encoded URL components back to readable text.
Runs locally · No data sent to server · Free, no signup
About URL Encode / Decode
URLs can only contain a limited set of characters. Spaces, accented characters, punctuation and many other symbols must be percent-encoded — replaced with a percent sign followed by their hexadecimal character code — before they can be used safely in a URL. This tool encodes strings for safe URL use, or decodes percent-encoded strings back to readable text, using the encodeURIComponent standard.
How to use URL Encode / Decode
Select Encode or Decode from the mode dropdown, paste your input in the text box and click Run. For encoding, enter a string with special characters and receive the URL-safe percent-encoded version. For decoding, paste a percent-encoded URL component and receive the original string.
When to use this tool
Use this when building URL query strings that contain spaces or special characters, when debugging malformed URLs in API requests or redirect chains, when encoding UTM tracking parameter values, when decoding a percent-encoded URL component received from an API or analytics platform, or when working with form data that needs to be URL-safe.
Privacy
URL encoding errors cause broken links, failed API requests, incorrect query strings and search indexing problems. Getting the encoding right matters, especially when working with user-generated content in URLs, UTM parameters and API query strings. All processing runs in your browser — nothing is uploaded.
Frequently asked questions
What characters get encoded?
All characters that are not unreserved in URL syntax are percent-encoded. Unreserved characters — letters A-Z, digits 0-9, hyphens, underscores, dots and tildes — are left unchanged. Spaces become %20, & becomes %26, and so on.
Should I encode an entire URL or just part of it?
You should encode individual components — query parameter values, path segments — not the full URL. Encoding the entire URL including its slashes, colons and question marks would break its structure.
What is the difference between encodeURI and encodeURIComponent?
encodeURI encodes a full URL and leaves structural characters like /, ? and : intact. encodeURIComponent encodes a single URL component and encodes everything including structural characters. This tool uses encodeURIComponent, which is the correct choice for encoding individual parameter values.
Why does a space sometimes become + instead of %20?
In HTML form encoding (application/x-www-form-urlencoded), spaces are encoded as +. In standard URL percent-encoding, spaces become %20. This tool uses %20, which is the correct encoding for URL components.