Tool Details

URL Encoder / Decoder

LiveDeveloper Utilities

Encode and decode URLs instantly. Supports encodeURIComponent, encodeURI, and full query string parsing -all in your browser.

Launch ToolView All ToolsRuns in your browser, no data sent to any server

About This Tool

Your redirect URL has a query parameter that contains another URL, and the ampersands are breaking the redirect chain. Or you're reading server logs and the request path is a wall of %20 and %3D characters. Paste the URL here to decode it into readable text, or encode your query parameter values so they survive transmission without breaking the URL structure. The built-in URL parser breaks any URL into protocol, host, path, and individual query parameters -helpful when debugging OAuth callbacks or deep links with nested parameters.

Examples

Encode a redirect URL parameter

Input

https://example.com/callback?next=https://app.example.com/dashboard&user=john

Output

https%3A%2F%2Fexample.com%2Fcallback%3Fnext%3Dhttps%3A%2F%2Fapp.example.com%2Fdashboard%26user%3Djohn

Decode a percent-encoded URL from logs

Input

%2Fapi%2Fusers%3Fname%3DJane%20Doe%26role%3Dadmin

Output

/api/users?name=Jane Doe&role=admin

Parse URL into components

Input

https://api.example.com:8080/v2/search?q=hello+world&page=2#results

Output

Protocol: https
Host: api.example.com:8080
Path: /v2/search
Query: q=hello+world, page=2
Hash: #results

Common Errors & Fixes

URIError: URI malformed -decodeURIComponent fails

The string contains a lone % not followed by two hex digits. Ensure all percent sequences are valid (%XX) or escape literal % as %25.

Double-encoded URL: %2520 instead of %20

The URL was encoded twice. Decode it once and use the result. Avoid calling encodeURIComponent on an already-encoded string.

Plus signs (+) not decoded as spaces

encodeURIComponent uses %20 for spaces, but form data uses +. Use decodeURIComponent(str.replace(/\+/g, ' ')) for form-encoded values.

Key Features

Encode text with encodeURIComponent for query parameters
Encode full URLs with encodeURI preserving URL structure
Decode any percent-encoded URL string instantly
Real-time encoding/decoding as you type
URL parser: break down any URL into protocol, host, path, and query params
One-click copy encoded or decoded output
Load sample URLs to quickly test the tool
100% client-side -no data sent to any server
Dark mode and light mode with responsive layout
Clean, distraction-free interface

FAQs

What does URL Encoder / Decoder do?

It converts special characters in text (like spaces, &, =, ?) into percent-encoded format safe for URLs, and decodes percent-encoded strings back into readable text. It also parses full URLs into their components.

What is the difference between encodeURI and encodeURIComponent?

encodeURI encodes a full URL but preserves characters that are part of URL structure (like ://?#&=). encodeURIComponent encodes everything except letters, digits, and - _ . ~ making it ideal for encoding individual query parameter values.

Is my data safe when using this tool?

Yes. All encoding and decoding happens 100% in your browser. No URLs or text data is ever sent to a server or stored anywhere.

Why do URLs need to be encoded?

URLs can only contain certain ASCII characters. Special characters like spaces, accented letters, and symbols (& = ? #) must be percent-encoded so they are transmitted correctly without breaking the URL structure.

Can I decode URLs with Unicode characters?

Yes. The tool fully supports UTF-8 decoding, so it correctly handles percent-encoded Unicode characters, emojis, and text in any language.

Need help building something?

We build web apps, APIs, and mobile apps with Laravel, Next.js, and Flutter.

Get a Free Quote