URL Encoder / Decoder
Encode and decode URL strings using percent encoding for links and APIs.
encodeURIComponent encodes everything except A-Z a-z 0-9 - _ . ! ~ * ' ( ) — use for query parameter values.
What is the Free URL Encoder / Decoder?
The free URL Encoder and Decoder converts text to and from percent-encoded (URL-safe) format instantly. Paste any string — including spaces, special characters, or non-ASCII text — into the Input textarea, choose encodeURIComponent for individual query values or encodeURI for full URLs, and the correctly encoded result appears immediately in the Output textarea. Click ⇄ Swap to move the output back to input for decoding in the other direction.
- → Encode query string parameter values before appending them to a URL
- → Decode percent-encoded URLs from server logs, redirects, or browser address bars
- → Fix URLs broken by spaces or special characters that fail API requests
- → Encode JSON strings or search terms for use in GET request query parameters
- → Inspect and clean up URL-encoded form data from HTTP POST bodies
How to Use the Free URL Encoder / Decoder
- 1 Paste your text or URL into the Input textarea.
- 2 Choose the encoding mode: encodeURIComponent encodes everything including
&,=, and/— best for individual query parameter values. encodeURI preserves URL structure characters like://,/, and?— best for full URLs. - 3 The encoded result appears instantly in the Output textarea.
- 4 To decode a percent-encoded string, click ⇄ Swap to move the output into the input, then the decoded text will appear as output.
- 5 Click Copy to copy the result to your clipboard.
Key Features
- 🔗 Two encoding modesencodeURIComponent for query values; encodeURI for full URLs — choose the right one for your use case.
- 🔄 Encode & DecodeConvert in both directions — encode special characters to percent-encoding or decode them back.
- ⇄ Swap buttonMove output back into input instantly for easy round-trip testing.
- ⚡ Live outputResults update as you type.
- 🌍 Unicode supportCorrectly handles emoji, accented characters, and all non-ASCII text.
Example Usage
hello world & category=books?q=clean code
hello%20world%20%26%20category%3Dbooks%3Fq%3Dclean%20code
Frequently Asked Questions about the Free URL Encoder / Decoder
- What is the free URL Encoder / Decoder?
- Encode and decode URL strings using percent encoding for links and APIs.
- Is the URL Encoder / Decoder free to use?
- Yes, the URL Encoder / Decoder is completely free. No account, subscription, or signup is required — ever.
- Does my data get uploaded anywhere?
- No. The URL Encoder / Decoder runs entirely in your browser. Your data is never sent to any server.
- Does it work offline?
- Yes. Once the page has loaded, the tool works without an internet connection.
- Which browsers are supported?
- All modern browsers — Chrome, Firefox, Safari, and Edge. No plugins or extensions required.
- What is the difference between encodeURIComponent and encodeURI?
- encodeURIComponent encodes nearly all special characters — including &, =, +, /, ?, and # — making each value safe to embed inside a URL. encodeURI preserves URL-structure characters and is designed for encoding a full URL without breaking its structure. Use encodeURIComponent when building query strings; use encodeURI only when encoding a complete URL.
- Why does %20 appear instead of + for spaces?
- Both %20 and + can represent a space in URLs, but in different contexts. %20 (percent-encoding per RFC 3986) works universally everywhere. The + sign represents a space only in the application/x-www-form-urlencoded format used by HTML forms. This tool uses %20, which is always safe regardless of context.
Related Free Developer Utilities
JSON Formatter
Format, validate, and beautify JSON data with syntax highlighting.
JSON Validator
Validate JSON syntax and get clear error messages for invalid JSON.
XML Formatter
Format and prettify XML code with proper indentation.
YAML Formatter
Format and validate YAML files with clear syntax error reporting.
Base64 Encoder / Decoder
Encode and decode Base64 strings instantly in your browser.
JWT Decoder
Decode and inspect JSON Web Token headers and payloads without verification.