URL Encoder & Decoder
Safely convert query parameters and special characters into standard percent-encoded format (RFC 3986) or restore encoded URLs into human-readable text.
What This Tool Does & Problem It Solves
The URL Encoder and Decoder converts text into percent-encoded strings safe for query parameters, or decodes percent-encoded URLs back into human-readable text. It solves broken links and corrupted query strings caused by special characters like spaces, slashes, ampersands, or non-ASCII letters.
Step-by-Step Instructions
- Enter or paste your text or URL into the input area.
- Choose encoding mode: "Component" (encodes reserved punctuation like
?&=) or "Full URL" (preserves protocol and domain slashes). - Click "Encode" to produce percent-encoded output, or "Decode" to decode percent escapes.
- Copy your converted URL string to clipboard.
Common Practical Use Cases
- API Query Parameter Construction: Safely encode search terms like "c++ & python" into
c%2B%2B%20%26%20pythonfor GET requests. - OAuth & Webhook Redirection: Encode complex callback URLs inside redirect parameter strings.
- Decoding Logged Requests: Decode percent-encoded tracking URLs in server access logs to read actual user queries.
Realistic Example & Expected Output
https://example.com/search?q=free tools & web=1
Component: "https%3A%2F%2Fexample.com%2Fsearch%3Fq%3Dfree%20tools%20%26%20web%3D1" Full URL: "https://example.com/search?q=free%20tools%20&%20web=1"
Technical Specifications & Mechanics
Built using standard browser APIs: encodeURIComponent() and decodeURIComponent() for component mode, and encodeURI() and decodeURI() for full URL mode. Catches malformed percent-escape sequences gracefully.
Limitations & Browser Boundaries
Handles syntactic RFC 3986 percent-encoding transformation; does not verify whether destination hostnames or server endpoints exist on the web.
Privacy & Security Guarantee
100% client-side memory execution. No URLs or queries are logged or shared.
Frequently Asked Questions
When should I use Component vs Full URL mode?
Use Component mode when encoding query parameter values (so & and = are escaped). Use Full URL mode when encoding an entire address where protocol (https://) and domain slashes must remain intact.
How does it handle non-Latin characters and emojis?
It converts them into their UTF-8 byte representation and encodes each byte as a percent-escape (e.g. %F0%9F%9A%80 for 🚀).
What happens if I try to decode invalid percent sequences?
The tool catches the URIError and displays a clear alert pointing out the malformed sequence.