URL Encoder and Decoder — Encode Special Characters for Safe URL Transmission
Our free URL encoder and decoder converts text and URLs to and from percent-encoding (URL encoding), making special characters safe for use in URLs, query strings, form data and API requests. Essential for web developers, API integrators and anyone building or debugging HTTP requests.
What is URL Encoding?
URL encoding (also called percent-encoding) replaces unsafe characters in a URL with a % sign followed by two hexadecimal digits representing the character's ASCII code. For example, a space becomes %20, an ampersand becomes %26, and a forward slash becomes %2F. This is necessary because URLs can only contain a limited set of safe characters — letters, digits, hyphens, underscores, periods and tildes.
Characters That Must Be Encoded in URLs
- Space →
%20(or + in form data) - & →
%26(ampersand separates query parameters) - = →
%3D(equals separates parameter names and values) - + →
%2B(plus is used as space in form encoding) - / →
%2F(forward slash is a path separator) - ? →
%3F(question mark starts the query string) - # →
%23(hash denotes URL fragment) - @ →
%40(at sign used in authentication URLs)
URL Encoding vs Base64 Encoding
URL encoding is used to encode individual characters within a URL. Base64 encoding converts binary data to text for safe transmission in contexts that only support text (like HTTP headers or JSON). They serve different purposes — URL encoding for URL safety, Base64 for binary-to-text conversion. Never use Base64 as a security measure — it provides no encryption.