Skip to main content

URL Encoder

Percent-encode a string for a query value, a full URI, or a form body.

Rated 4.6 out of 5 based on 387 reviews

Input
Output

How to URL-encode

  1. Paste the raw string.
  2. Choose Component for a query or path value, URI for a full URL, or Form when the receiver expects + for spaces.
  3. Copy the percent-encoded output.

Percent-encoding

URL encoding

ComponentencodeURIComponent. Space becomes %20
URIencodeURI. Leaves URL structure intact
Formapplication/x-www-form-urlencoded. Space becomes +

What URL encoding is

Percent-encoding lets reserved characters travel inside a URI. Component is correct for query values and most path segments. URI keeps ://, ?, and similar structure so you can encode a full URL. Form matches HTML form bodies, where space becomes +.

Pair with the URL decoder or browse other encoding tools.

URL encoding is not Base64

Percent-encoding uses % and hex bytes. Base64 uses a 64-character alphabet. If the other system expects Base64, open the Base64 encoder.

URL encoding questions

Why is space %20 instead of +?
That is the Component mode. Switch Encode as to Form if the receiver uses application/x-www-form-urlencoded.
Is this the same as Base64?
No. Base64 is a different alphabet. Use the Base64 encoder for that.