URL Encode / Decode

Encode or decode URL components with percent-encoding.

Runs in your browser All processing happens locally. Your data never leaves this device.

Overview

URLs may only contain a limited set of ASCII characters. Percent-encoding (URL encoding) represents any other byte as % followed by two hex digits, so spaces, non-ASCII text, and reserved characters can travel safely in a URL. This tool encodes and decodes text locally.

How to use

  1. Choose Encode or Decode.
  2. Toggle Whole URI to switch between encodeURIComponent (a single value) and encodeURI (a full URL).
  3. Type or paste your input; the result updates instantly.

Examples

FAQ

What is the difference between encodeURIComponent and encodeURI?
encodeURIComponent escapes everything that is not a URL-safe character, so it is correct for a single query value or path segment. encodeURI leaves characters that are legal in a full URL (colon, slash, question mark, ampersand) unescaped, so it is for encoding a whole URL. Use the Whole URI toggle to switch.
Is my input sent anywhere?
No. Encoding and decoding run in your browser using the built-in encodeURIComponent/decodeURIComponent functions. Nothing is uploaded.
Why did decoding fail?
Decoding fails on malformed percent sequences (for example a lone % or %ZZ). Check that every % is followed by two hexadecimal digits.