URL Encoder / Decoder

Percent-encode or decode URLs, query strings and URI components safely.

Encode and Decode URLs and Query String Parameters

URLs may only contain a restricted set of ASCII characters. Anything else — spaces, ampersands inside a value, question marks, slashes in a parameter, or any non-Latin character — must be percent-encoded as % followed by its hexadecimal byte value. Skip that step and your query string silently breaks apart at the first stray ampersand.

This tool exposes both of the encoding functions you actually need, and explains which to use. encodeURIComponent escapes everything unsafe and is what you want for individual parameter values; encodeURI leaves the structural characters of a URL intact and is for encoding a complete address.

Key features

  • Both encoding modes — full-URI encoding and component encoding, with a plain-language explanation of each.
  • Unicode support — any script encodes correctly via UTF-8 percent-encoding.
  • Query string breakdown — paste a full URL to see each parameter decoded into a readable table.
  • Bidirectional — switch between encode and decode without retyping your input.
100% client-side — no data leaves your machine

This tool runs entirely inside your browser using native Web APIs. Your files and text are never uploaded to a server, never logged and never shared with third parties.

How to use: URL Encoder / Decoder

  1. Pick a direction
    Switch between Encode and Decode depending on whether you are building a URL or reading one.
  2. Choose the encoding mode
    Use Component for a single parameter value, and Full URI when encoding an entire address that must keep its slashes and colons.
  3. Paste your input
    The result appears instantly in the output pane as you type.
  4. Copy the result
    Copy the encoded or decoded string with one click.

Technical specifications

Processing locationEntirely in your browser — no server round trip
Data uploadedNone. Files and text never leave your device
PriceFree — no account, no trial, no usage cap
CategoryDeveloper
Works offlineYes, once the page has loaded
Browser supportChrome 90+, Edge 90+, Firefox 90+, Safari 15+
Interface languagesEnglish, 中文, हिन्दी, Español, العربية

Frequently asked questions

What is the difference between encodeURI and encodeURIComponent?

encodeURI preserves the characters that give a URL its structure — : / ? # & = — so it is safe for a complete address. encodeURIComponent escapes those too, which is correct for a single parameter value where a raw & or = would otherwise be read as a separator.

Why does a space become %20 sometimes and + other times?

Percent-encoding represents a space as %20. The + form comes from the older application/x-www-form-urlencoded format used by HTML form submissions. Both appear in the wild; %20 is correct for URL paths.

Do I need to encode a URL that is already encoded?

No — double-encoding is a common bug. It turns each % into %25, so %20 becomes %2520 and the destination server receives literal text instead of a space. Decode first if you are unsure.

Is URL encoding a security measure?

Not on its own. It prevents parsing errors and some classes of injection, but it is not a substitute for server-side validation and proper output escaping.

Related tools

Back to all tools