Enter the text that you wish to encode or decode:
Use the web tool from above to both encode or decode a string of text. For worldwide interoperability, URIs must be encoded uniformly. To map the extensive range of characters used global into the 60 or so allowed characters in a URI, a -step technique is used:
Convert the man or woman string into a sequence of bytes using the UTF-8 encoding
Convert each byte that isn't always an ASCII letter or digit to %HH, wherein HH is the hexadecimal price of the byte
As an instance, the string: François ,might be encoded as: Franp.CC3%A7ois
(The "ç" is encoded in UTF-eight as bytes C3 (hex) and A7 (hex), that are then written as the three characters "%c3" and "%a7" respectively.) this can make a URI as an alternative lengthy (up to nine ASCII characters for a unmarried Unicode person), but the aim is that browsers handiest want to show the decoded form, and plenty of protocols can ship UTF-eight with out the %HH escaping.
What is URL encoding?
URL encoding stands for encoding positive characters in a URL by using replacing them with one or greater character triplets that encompass the percentage individual "%" observed by way of hexadecimal digits. The two hexadecimal digits of the triplet(s) represent the numeric fee of the replaced person.
The time period URL encoding is a piece inexact because the encoding system is not constrained to URLs (Uniform resource Locators), but also can be applied to any other URIs (Uniform useful resource Identifiers) including URNs (Uniform resource Names). Consequently, the time period percentage-encoding must be desired.
Which Characters Are Allowed in a URL?
The characters allowed in a URI are both reserved or unreserved (or a percentage character as a part of a percent-encoding). Reserved characters are the ones characters that from time to time have unique meaning, even as unreserved characters have no such which means. The usage of percentage-encoding, characters which otherwise could not be allowed are represented the usage of allowed characters. The sets of reserved and unreserved characters and the circumstances under which sure reserved characters have unique meaning have modified slightly with every revision of specs that govern URIs and URI schemes.
In step with RFC 3986, the characters in a URL must be taken from a described set of unreserved and reserved ASCII characters. Any other characters are not allowed in a URL.
The unreserved characters may be encoded, but must no longer be encoded. The unreserved characters are:
A B C D E F G H I J ok L M N O P Q R S T U V W X Y Z a b c d e f g h i j okay l m n o p q r s t u v w x y z zero 1 2 three 4 5 6 7 8 9 - _ . ~
The reserved characters have to be encoded simplest beneath certain circumstances. The reserved characters are:
! * ' ( ) ; : @ & = + $ , / ? % # [ ]
Encoding/deciphering a bit of textual content
RFC 3986 does no longer outline in line with which character encoding table non-ASCII characters (e.G. The umlauts ä, ö, ü) have to be encoded. As URL encoding involves a pair of hexadecimal digits and as a pair of hexadecimal digits is equal to 8 bits, it might theoretically be feasible to use one of the eight-bit code pages for non-ASCII characters (e.G. ISO-8859-1 for umlauts).
Alternatively, as many languages have their personal 8-bit code page, dealing with these kinds of one of a kind eight-bit code pages would be a quite bulky aspect to do. Some languages do no longer even fit into an 8-bit code page (e.G. Chinese). Consequently, RFC 3629 proposes to use the UTF-eight man or woman encoding table for non-ASCII characters. The following tool takes this under consideration and offers to pick out between the ASCII character encoding table and the UTF-eight man or woman encoding table. If you opt for the ASCII character encoding table, a caution message will pop up if the URL encoded/decoded textual content includes non-ASCII characters.
While and why might you operate URL encoding?
When records that has been entered into HTML paperwork is submitted, the form area names and values are encoded and sent to the server in an HTTP request message the usage of technique GET or publish, or, historically, via e mail. The encoding used by default is based on a completely early model of the general URI percentage-encoding rules, with a number of adjustments inclusive of newline normalization and replacing spaces with "+" rather than "%20". The MIME sort of statistics encoded this manner is software/x-www-form-urlencoded, and it is currently described (nevertheless in a very old way) inside the HTML and XForms specifications. Further, the CGI specification consists of guidelines for a way internet servers decode information of this kind and make it to be had to applications.
When sent in an HTTP GET request, software/x-www-form-urlencoded records is blanketed inside the query element of the request URI. While sent in an HTTP put up request or thru email, the statistics is positioned within the frame of the message, and the name of the media kind is blanketed in the message's content-type header.