URL Encoder
Percent-encode text for safe use in a URL or query string, live as you type.
Type in either field — the other updates live, both directions. Uses encodeURIComponent, safe for query-string values. Runs entirely in your browser — safe for URLs carrying API keys, access tokens, or other secrets.
Need the opposite? URL Decoder
What is URL Encoder?
URL encoding, also called percent-encoding, converts characters that aren't safe to use directly inside a URL (spaces, &, ?, =, and any non-ASCII character) into a %XX format so the URL remains valid and unambiguous for browsers and servers to parse. Type plain text or a URL containing special characters and get the percent-encoded, URL-safe version instantly, both directions at once, so editing either field updates the other live. This is essential when building a query string value by hand, since an unencoded & or = inside a value would be misread as a separate parameter.
How to Use the URL Encoder
- 1
Type or Paste the Text: Enter plain text or a value you plan to use inside a URL, such as a search term.
- 2
Read the Encoded Result Instantly: The percent-encoded, URL-safe version appears automatically as you type.
- 3
Copy the Result: Use the copy button to copy the encoded value for use in a query string or API request.
How Percent-Encoding Works
Only a limited set of ASCII characters (letters, digits, and a handful of punctuation marks like - _ . ~) are safe to use unescaped inside a URL. Every other character (spaces, reserved symbols such as & ? = /, and any non-ASCII character) is replaced with a % followed by two hexadecimal digits representing that character's byte value. Non-ASCII characters are first converted to UTF-8 bytes, and each byte becomes its own %XX sequence, so a single accented or non-Latin character can turn into multiple percent-encoded triplets.
Example
Encoding hello world & more=1 produces hello%20world%20%26%20more%3D1: the space becomes %20, & becomes %26, and = becomes %3D.
A multi-byte example: café encodes to caf%C3%A9, since é's UTF-8 representation is the two bytes C3 A9, each written as a separate %XX sequence.Frequently Asked Questions
Common questions about URL Encoder.