TTTinyOfficeToolsFree tools for work and creators

Developer / 5 min read

URL Encoding Explained

Understand percent encoding, query strings, and why spaces and symbols look different inside URLs.

URLs cannot contain every character directly

URLs have special characters that separate paths, query strings, and parameters. When text includes spaces, symbols, or non-Latin characters, it often needs to be encoded so the URL remains valid.

Percent encoding replaces characters with a percent sign followed by a code. For example, a space may become %20.

Where encoding shows up

You will often see encoded text in search URLs, redirect links, API requests, analytics links, and form submissions.

  • Encode text before putting it inside a query parameter.
  • Decode text when debugging a URL that is hard to read.
  • Do not treat URL encoding as a privacy feature.

Debug carefully

If a link breaks after copying it into another tool, check whether it was encoded twice or not encoded at all. Both mistakes can change the meaning of the URL.