URL Encoder
URL Encoder is used to encode or escape text that is normally unsafe for transmission in URL.
All processing happens on the client-side, locally in your browser. No data is uploaded.
Paste plain text below
URL encoded text
Settings
How the input is converted. Each is explained below.
History
- 2017-08-20Tool Launched
Settings explained
- Encode reserved characters
Reserved characters give a URL its structure: & and = separate the parameters of a query, ? starts it, # starts the fragment, / and : separate the parts of the address. Turn this on to encode a value that goes inside a URL, such as a search term, so that none of them break it (encodeURIComponent). Turn it off to encode a whole URL and keep its structure (encodeURI).
Inputname=Bill Gates&og=true
Encode reserved characters onname%3DBill%20Gates%26og%3Dtrue
Encode reserved characters offname=Bill%20Gates&og=true
Background
Certain characters need to be encoded (escaped) in URL. This is also called as Percent encoding.
Read more at wikipedia
Example Substitutions
How to do URL encoding in various programming languages
| Language | Encode | Decode | Example | Documentation |
|---|---|---|---|---|
| C# | System.Web.HttpUtility.UrlEncode() | System.Web.HttpUtility.UrlDecode() | UrlEncode() UrlDecode() | UrlEncode() UrlDecode() |
| VB .NET | System.Web.HttpUtility.UrlEncode() | System.Web.HttpUtility.UrlDecode() | UrlEncode() UrlDecode() | UrlEncode() UrlDecode() |
| Java | java.net.URLEncoder.encode() | java.net.URLDecoder.decode() | encode() decode() | encode() decode() |
| JavaScript | encodeURI() | decodeURI() | encodeURI() decodeURI() | encodeURI() decodeURI() |
| Python | urllib.urlencode() | urllib.unquote() | urlencode() unquote() | urlencode() unquote() |
| Ruby | uri.URI.escape() | uri.URI.unescape() | escape() unescape() | Documentation |