URL Encode Online

Percent-encode text for query strings, API calls and redirect URLs — live as you type. Component or full-URI mode. Nothing leaves your browser.

Advertisement

How to URL-encode text

  1. Type or paste your text — encoding happens live.
  2. Pick Component for a single query-string value (escapes everything), or Full URI to clean a complete URL without breaking its structure.
  3. Copy the result. Use ⇄ Swap to verify it decodes back correctly.

Component vs. full-URI encoding — which one?

Use Component (the default) when you're building a URL and inserting a value into it: search terms, redirect targets, email addresses in query strings. It escapes / ? & = # so your value can't hijack the URL structure. Use Full URI when you already have a complete URL that just needs its spaces and special characters fixed — it leaves the structural characters alone so the URL keeps working.

Frequently asked questions

When do I need to URL-encode text?

Whenever text goes into a URL and contains spaces, &, ?, =, #, non-ASCII characters or emoji. Unencoded special characters break query strings, redirect URLs, and API calls.

What's the difference between component and full-URI encoding?

Component encoding (encodeURIComponent) escapes everything including / ? & = — use it for individual query-string values. Full-URI encoding (encodeURI) keeps URL structure characters intact — use it to clean up a complete URL without breaking it.

Why does a space become %20?

URLs can't contain literal spaces, so each unsafe byte is replaced by % followed by its hex value — a space is byte 0x20, hence %20. HTML forms sometimes use + for spaces instead, which is why you see both.

Is my text uploaded anywhere?

No. Encoding runs entirely in your browser — URLs with tokens or session IDs never leave your machine.

Advertisement

More free developer tools