Skip to content
UtilHQ

Free URL Encoder / Decoder

URLs (Uniform Resource Locators) are strict about what characters they accept.

100% Free No Data Stored Instant

URL Encoder

Did you know?

URLs can only contain a limited set of characters (ASCII). Characters like spaces, emojis, or symbols (`&`, `=`, `?`) inside query parameters must be "percent-encoded" (e.g., Space becomes `%20`) to be transmitted correctly over the internet.

Ad Space
Ad Space

Share this tool

About This Tool

URLs (Uniform Resource Locators) are strict about what characters they accept. If you try to put a space, a slash, or an emoji directly into a URL's query string, it will break. Browsers, servers, and APIs all expect URLs to contain only a specific set of safe ASCII characters. Anything outside that set must be percent-encoded before transmission. Our Free URL Encoder/Decoder handles this conversion for you instantly. It converts special characters into their percent-encoded format (like converting a space to %20) so they can be safely transmitted across the web. It also decodes messy, encoded URLs back into human-readable text. This is essential when building API requests, debugging query strings, constructing redirect URLs, or working with webhook payloads. Paste your text above, choose encode or decode, and get the result in a single click. A swap button lets you quickly reverse the operation, sending the output back to the input for round-trip testing. Your data stays completely private and is never sent to any server or logged in any way.

Why Encode URLs?

The internet was built on ASCII. Characters outside the standard alphanumeric set (A-Z, 0-9) are unsafe in URLs. Additionally, reserved characters like ?, &, /, and = have special structural meanings in URL syntax. If your data contains these characters (for example, a search query like c++), they must be escaped (c%2B%2B) so the server does not misinterpret them as URL delimiters or commands. Without proper encoding, query parameters merge together, paths break, and servers return 400 Bad Request errors.

Common Encoded Values

Here are the most frequently encountered percent-encoded characters:

  • Space becomes %20 (or + in form data)
  • ! becomes %21
  • " becomes %22
  • # becomes %23 (hash/fragment delimiter)
  • $ becomes %24
  • % becomes %25 (the escape character itself)
  • & becomes %26 (query parameter separator)
  • + becomes %2B
  • = becomes %3D (key-value separator)
  • / becomes %2F (path separator)

Memorizing these is not necessary since this tool handles the conversion automatically, but understanding them helps when debugging URLs in server logs or network traces.

Full URL Encoding vs Component Encoding

There are two approaches to URL encoding, and choosing the wrong one is a common source of bugs. Full URL encoding encodes a complete URL string while preserving structural characters like ://, /, ?, and &. Component encoding encodes a single value, such as a query parameter or path segment, escaping every special character including colons and slashes. Our tool uses the component encoding approach for maximum safety, which is the correct choice when encoding individual parameter values. For example, full URL encoding on https://example.com/path?q=hello world preserves the URL structure but encodes the space, while component encoding on hello world encodes everything including structural characters. When building URLs programmatically, always encode each parameter value separately using component encoding, then assemble the full URL with the structural characters.

Common Use Cases

URL encoding is required in many web development scenarios. When building API requests with query parameters that contain user input, each parameter value must be encoded to prevent injection or parsing errors. Constructing OAuth callback URLs requires encoding the redirect URI as a parameter within another URL. Generating shareable links with pre-filled form data requires encoding the values. Parsing and debugging webhook payloads from third-party services often involves decoding URL-encoded POST bodies. Working with email tracking pixels and marketing UTM parameters also frequently requires proper encoding of campaign names and source identifiers that may contain spaces or special characters.

URL Encoding Standards (RFC 3986)

The modern URL encoding standard is defined in RFC 3986. It specifies that unreserved characters (A-Z, a-z, 0-9, hyphen, period, underscore, tilde) do not need encoding. All other characters should be percent-encoded using their UTF-8 byte values. For non-ASCII characters like emojis or accented letters, each byte of the UTF-8 encoding is individually percent-encoded. For example, the euro sign is encoded as %E2%82%AC because its UTF-8 representation is three bytes: E2, 82, AC. This standard replaced the older RFC 2396 and provides better support for internationalized URLs.

Frequently Asked Questions

What is Percent-Encoding?
Percent-encoding (also called URL encoding) represents a character using a percentage sign followed by its two-digit hexadecimal byte value. For example, the ASCII value for space is 32 in decimal or 20 in hexadecimal, so it becomes %20. Multi-byte UTF-8 characters produce multiple percent-encoded triplets, one for each byte in their encoding.
Why does space sometimes become + instead of %20?
Historically, the application/x-www-form-urlencoded content type used in HTML form submissions replaced spaces with + signs. This is a legacy behavior from early web standards. The modern URL encoding standard (RFC 3986) uses %20 for spaces. Most modern APIs and frameworks prefer %20, but + is still commonly seen in query strings submitted through HTML forms. Both are valid, but %20 is more universally compatible.
Is my data sent to a server when I use this tool?
No. All encoding and decoding happens entirely on your device. Your text, URLs, and query parameters never leave your computer. There are no network requests, no server-side processing, and no data logging of any kind.
U

Reviewed by the UtilHQ Team

Our tools are verified for accuracy. Results are estimates for planning purposes.