About this url encode & decode
URLs cannot contain spaces, ampersands and most non-English characters raw โ they must be percent-encoded (a space becomes %20). This tool encodes text so it is safe inside a link or query string, and decodes percent-encoded text back to readable form.
How to use it
- Paste your text or URL part.
- Encode to make it URL-safe, or decode to read it.
- Copy the result.
The formula
Worked example
Frequently asked questions
What is the difference between + and %20 for spaces?
In query strings from HTML forms, + can mean a space. encodeURIComponent (used here) produces %20, which is unambiguous and safest.
Should I encode a whole URL?
Encode the parts you add โ query values, search terms, filenames. Encoding a full URL would escape its :// and / structure too.
Which characters never need encoding?
Letters, digits and - _ . ! ~ * ' ( ) pass through encodeURIComponent unchanged.