URL Encoder and Decoder

URL Encoder and Decoder

Encode text safely for a URL or decode percent-encoded text instantly in your browser.

Input length
Output length
Changed characters

How the URL Encoder and Decoder works

The URL Encoder and Decoder converts characters that are unsafe or have special meaning in web addresses into percent-encoded values. For example, a space becomes %20, an ampersand becomes %26, and a percent sign becomes %25. Decoding reverses that process.

This tool follows the browser JavaScript encoding functions described in the MDN encodeURIComponent reference and the URI syntax standardized by RFC 3986.

Choose the correct encoding format

URL component

Use URL component encoding for a query value, path segment, search term or form field. It encodes reserved characters such as question marks, ampersands and equals signs so the value cannot be confused with URL structure.

Form data

Form encoding is similar to component encoding, but spaces become plus signs. This matches the common application/x-www-form-urlencoded convention used by HTML forms.

Complete URL

Complete URL encoding preserves structural characters including colons, slashes, question marks, ampersands, equals signs and fragments. Use it only when the input is already a full URL and you want to encode unsafe characters without hiding the URL structure.

URL encoding examples

Component input: summer sale 20% & free shipping
Encoded result: summer%20sale%2020%25%20%26%20free%20shipping

Decoded input: red%20shoes%3Fsize%3D10
Decoded result: red shoes?size=10

Why URL encoding matters

URLs use reserved characters to separate schemes, domains, paths, queries and fragments. Encoding prevents ordinary text from accidentally changing that structure. It is useful for search parameters, redirect links, API requests, analytics tags, email links and filenames containing spaces or non-ASCII characters.

URL Encoder and Decoder percent encoding process diagram

Accuracy, privacy and limitations

The tool uses native browser functions and supports Unicode text. Decoding malformed percent sequences such as a lone percent sign is invalid, so the calculator displays a clear error instead of returning misleading text. URL encoding is not encryption and does not make confidential information secure. Never place passwords, payment information or private tokens in a public URL.

Common uses for encoded URLs

Use this URL Encoder and Decoder when building campaign links, sharing search queries, testing API parameters or preparing redirect destinations. Always encode each dynamic value before adding it to a query string. This prevents spaces and reserved symbols from breaking the address while preserving the exact original text for later decoding.

Frequently asked questions

What is percent encoding?

Percent encoding represents a character with a percent sign followed by its hexadecimal byte value. A space is commonly %20 and a slash is %2F when encoded as part of a component.

Should I encode an entire URL?

Usually no. Encode individual parameter values with URL component mode. Use complete URL mode only when you intentionally want to preserve URL separators.

Why does a space sometimes become a plus sign?

HTML form encoding traditionally uses a plus sign for spaces. Standard URL component encoding uses %20.

Can the tool decode plus signs as spaces?

Yes. Select Form data before decoding. Component and complete URL modes leave literal plus signs unchanged.

Is URL encoding secure?

No. Anyone can decode it. Encoding ensures correct URL syntax; it does not provide secrecy or authentication.

Does it work with accented letters and emoji?

Yes. Unicode characters are converted to their UTF-8 percent-encoded representation and can be decoded back to the original text.