URL Encoder / Decoder — Encode & Decode Query Strings, Paths & Params

URL Encoder / Decoder

Percent-encode any string to make it safe for URLs (query strings, paths, fragments) — or decode an encoded URL back to its original form. Essential for debugging, tracking links, and any URL containing spaces, emoji, or special characters.

Saisir

Sortir

How to use the URL Encoder/Decoder

Paste your string or URL. Pick a mode: `encodeURIComponent` for parameter values (the most common), `encodeURI` for whole URLs (preserves /, ?, &), or `decodeURIComponent` to reverse either. The output updates in real time.

Pourquoi cet outil est important

URLs only allow ASCII letters, digits, and a small set of reserved characters. Spaces, emoji, accented letters, ampersands inside values, and quote marks all need to be percent-encoded. Without encoding, your URL breaks at the first ampersand inside a value, gets truncated at the first space, or 404s on a UTF-8 character. Percent-encoding is the standard fix.

Cas d'utilisation courants

  • Building UTM-tagged campaign URLs that contain spaces or accented characters
  • Encoding form data for GET requests
  • Debugging tracking links where parameters look corrupted
  • Constructing API endpoints with user-generated content in the path
  • Encoding non-Latin characters (Japanese, Arabic, Cyrillic) for URLs
  • Decoding encoded URLs from logs to make them readable

encodeURI vs. encodeURIComponent

`encodeURI` is for whole URLs — it preserves URL structure characters like /, ?, &, # because those are meaningful in a URL. `encodeURIComponent` is for individual values — it encodes EVERYTHING that needs encoding including / and &. Use encodeURIComponent for query parameter values. Use encodeURI for entire URLs you assembled from trusted parts.

Foire aux questions

Why does “+” become “%20” sometimes?
Both can represent a space in a URL — but only in different parts. In query strings, both work. In paths, only %20 works. Encoders consistently use %20 to avoid ambiguity.

Do I need to encode hashtags and ampersands?
In a parameter value: yes (& would otherwise be read as the next parameter). In a URL fragment after #: ampersand is fine. In a URL path: encode hash but leave slashes alone.

Why does my emoji get mangled in URLs?
Emoji are multi-byte UTF-8. Many systems don\u2019t percent-encode them automatically. Always run user-generated content through encodeURIComponent before adding to a URL.

Will encoding break my tracking pixel?
Only if encoded twice. Watch for double-encoding (%2520 instead of %20). Decode once, then encode once.

Need clean UTM tracking across paid, organic, and email?

Riman Agency builds attribution programs with bulletproof URL hygiene.

Get a Tracking Audit

Passer au panneau d'accessibilité