<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://rs-485.com/index.php?action=history&amp;feed=atom&amp;title=Percent-encoding</id>
	<title>Percent-encoding - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://rs-485.com/index.php?action=history&amp;feed=atom&amp;title=Percent-encoding"/>
	<link rel="alternate" type="text/html" href="https://rs-485.com/index.php?title=Percent-encoding&amp;action=history"/>
	<updated>2026-05-04T00:07:07Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.42.3</generator>
	<entry>
		<id>https://rs-485.com/index.php?title=Percent-encoding&amp;diff=2365&amp;oldid=prev</id>
		<title>Admin: Imported missing template from Wikipedia</title>
		<link rel="alternate" type="text/html" href="https://rs-485.com/index.php?title=Percent-encoding&amp;diff=2365&amp;oldid=prev"/>
		<updated>2026-05-03T17:10:58Z</updated>

		<summary type="html">&lt;p&gt;Imported missing template from Wikipedia&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;{{Short description|Method of encoding characters in a URI}}&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Percent-encoding&amp;#039;&amp;#039;&amp;#039;, also known as &amp;#039;&amp;#039;&amp;#039;URL encoding&amp;#039;&amp;#039;&amp;#039;, is a method to [[binary-to-text encoding|encode]] arbitrary data in a [[uniform resource identifier]] (URI) using only the [[ASCII|US-ASCII]] characters legal within a URI. Percent-encoding is used to ensure special characters do not interfere with the URI&amp;#039;s structure and interpretation. Special characters are replaced with a percent sign (%) followed by two hexadecimal digits representing the character&amp;#039;s byte value. For example, a space is commonly encoded as &amp;lt;code&amp;gt;%20&amp;lt;/code&amp;gt;:&lt;br /&gt;
&lt;br /&gt;
* original: &amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;http://example.com/my file.txt&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
* encoded: &amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;http://example.com/my%20file.txt&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Although it is known as &amp;#039;&amp;#039;URL encoding&amp;#039;&amp;#039;, it is also used more generally within the main [[Uniform Resource Identifier]] (URI) set, which includes both [[Uniform Resource Locator]] (URL) and [[Uniform Resource Name]] (URN). Consequently, it is also used in the preparation of data of the &amp;lt;code&amp;gt;application/x-www-form-urlencoded&amp;lt;/code&amp;gt; [[media type]], as is often used in the submission of HTML [[form (web)|form]] data in [[HTTP]] requests. Percent-encoding is not case-sensitive.&lt;br /&gt;
&lt;br /&gt;
== Percent-encoding in a URI ==&lt;br /&gt;
&lt;br /&gt;
The characters allowed in a URI are either &amp;#039;&amp;#039;reserved&amp;#039;&amp;#039; or &amp;#039;&amp;#039;unreserved&amp;#039;&amp;#039; (or a [[percent sign|percent character]] as part of a percent-encoding). &amp;#039;&amp;#039;Reserved&amp;#039;&amp;#039; characters are those characters that sometimes have special meaning. For example, [[forward slash]] characters are used to separate different parts of a URL (or, more generally, a URI). &amp;#039;&amp;#039;Unreserved&amp;#039;&amp;#039; characters have no such meanings. Using percent-encoding, reserved characters are represented using special character sequences. The sets of reserved and unreserved characters and the circumstances under which certain reserved characters have special meaning have changed slightly with each revision of specifications that govern URIs and URI schemes.&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|+RFC 3986 section 2.2 &amp;#039;&amp;#039;Reserved Characters&amp;#039;&amp;#039; (January 2005)&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;[[exclamation mark|!]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[number sign|#]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[dollar sign|$]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[ampersand|&amp;amp;]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[apostrophe (mark)|&amp;#039;]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[parenthesis|(]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[parenthesis|)]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[asterisk|&amp;lt;nowiki&amp;gt;*&amp;lt;/nowiki&amp;gt;]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[plus sign|+]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[Comma|,]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[slash (punctuation)|/]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[colon (punctuation)|:]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[semicolon|;]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[equal sign|=]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[question mark|?]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[At sign|@]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[square_bracket|[]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[square_bracket|&amp;lt;nowiki&amp;gt;]&amp;lt;/nowiki&amp;gt;]]&amp;lt;/code&amp;gt;&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|+RFC 3986 section 2.3 &amp;#039;&amp;#039;Unreserved Characters&amp;#039;&amp;#039; (January 2005)&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;[[A]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[B]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[C]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[D]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[E]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[F]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[G]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[H]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[I]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[J]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[K]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[L]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[M]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[N]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[O]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[P]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[Q]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[R]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[S]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[T]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[U]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[V]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[W]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[X]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[Y]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[Z]]&amp;lt;/code&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;[[a]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[b]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[c]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[d]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[e]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[f]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[g]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[h]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[i]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[j]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[k]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[l]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[m]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[n]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[o]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[p]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[q]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[r]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[s]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[t]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[u]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[v]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[w]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[x]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[y]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[z]]&amp;lt;/code&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;[[0 (number)|0]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[1 (number)|1]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[2 (number)|2]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[3 (number)|3]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[4 (number)|4]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[5 (number)|5]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[6 (number)|6]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[7 (number)|7]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[8 (number)|8]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[9 (number)|9]]&amp;lt;/code&amp;gt;&lt;br /&gt;
| &amp;lt;code&amp;gt;[[hyphen-minus|-]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[Full_stop|.]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[underscore|_]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[tilde|~]]&amp;lt;/code&amp;gt; || colspan=&amp;quot;13&amp;quot; | &amp;lt;!--empty--&amp;gt;&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Other characters in a URI must be percent-encoded.&lt;br /&gt;
&lt;br /&gt;
=== Reserved characters&amp;lt;span class=&amp;quot;anchor&amp;quot; id=&amp;quot;Percent-encoding reserved characters&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; ===&lt;br /&gt;
When a character from the reserved set (a &amp;quot;reserved character&amp;quot;) has a special meaning (a &amp;quot;reserved purpose&amp;quot;) in a certain context, and a URI scheme says that it is necessary to use that character for some &amp;#039;&amp;#039;other&amp;#039;&amp;#039; purpose, then the character must be &amp;#039;&amp;#039;percent-encoded&amp;#039;&amp;#039;. Percent-encoding a reserved character involves converting the character to its corresponding byte value in [[American Standard Code for Information Interchange|ASCII]] and then representing that value as a pair of [[hexadecimal]] digits (if there is a single hex digit, a [[leading zero]] is added). The digits, preceded by a [[percent sign]] (&amp;lt;code&amp;gt;%&amp;lt;/code&amp;gt;) as an [[escape character]], are then used in the URI in place of the reserved character.&lt;br /&gt;
(A non-ASCII character is typically converted to its byte sequence in [[UTF-8]], and then each byte value is represented as above.)&lt;br /&gt;
&lt;br /&gt;
The reserved character &amp;lt;code&amp;gt;/&amp;lt;/code&amp;gt;, for example, if used in the &amp;quot;path&amp;quot; component of a [[URI]], has the special meaning of being a [[Slash (punctuation)#Networking|delimiter]] &amp;#039;&amp;#039;between&amp;#039;&amp;#039; path segments. If, according to a given URI scheme, &amp;lt;code&amp;gt;/&amp;lt;/code&amp;gt; needs to be &amp;#039;&amp;#039;in&amp;#039;&amp;#039; a path segment, then the three characters &amp;lt;code&amp;gt;%2F&amp;lt;/code&amp;gt; or &amp;lt;code&amp;gt;%2f&amp;lt;/code&amp;gt; must be used in the segment instead of a raw &amp;lt;code&amp;gt;/&amp;lt;/code&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|+ Reserved characters after percent-encoding&lt;br /&gt;
|- align=&amp;quot;center&amp;quot;&lt;br /&gt;
| &amp;lt;code&amp;gt;[[exclamation mark|!]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[number sign|#]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[dollar sign|$]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[ampersand|&amp;amp;]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[apostrophe (mark)|&amp;#039;]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[parenthesis|(]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[parenthesis|)]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[asterisk|&amp;lt;nowiki&amp;gt;*&amp;lt;/nowiki&amp;gt;]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[plus sign|+]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[Comma|,]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[slash (punctuation)|/]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[colon (punctuation)|:]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[semicolon|;]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[equal sign|=]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[question mark|?]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[At sign|@]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[square_bracket|[]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[square_bracket|&amp;lt;nowiki&amp;gt;]&amp;lt;/nowiki&amp;gt;]]&amp;lt;/code&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;%21&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;%23&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;%24&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;%26&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;%27&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;%28&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;%29&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;%2A&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;%2B&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;%2C&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;%2F&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;%3A&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;%3B&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;%3D&amp;lt;/code&amp;gt;|| &amp;lt;code&amp;gt;%3F&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;%40&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;%5B&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;%5D&amp;lt;/code&amp;gt;&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Reserved characters that have no reserved purpose in a particular context may also be percent-encoded but are not semantically different from those that are not.&lt;br /&gt;
&lt;br /&gt;
In the &amp;quot;[[query string|query]]&amp;quot; component of a URI (the part after a &amp;lt;code&amp;gt;?&amp;lt;/code&amp;gt; character), for example, &amp;lt;code&amp;gt;/&amp;lt;/code&amp;gt; is still considered a reserved character but it normally has no reserved purpose, unless a particular URI scheme says otherwise. The character does not need to be percent-encoded when it has no reserved purpose.&lt;br /&gt;
&lt;br /&gt;
URIs that differ only by whether a reserved character is percent-encoded or appears literally are normally considered not equivalent (denoting the same resource) unless it can be determined that the reserved characters in question have no reserved purpose. This determination is dependent upon the rules established for reserved characters by individual URI schemes.&lt;br /&gt;
&lt;br /&gt;
=== Unreserved characters&amp;lt;span class=&amp;quot;anchor&amp;quot; id=&amp;quot;Percent-encoding unreserved characters&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; ===&lt;br /&gt;
Characters from the unreserved set never need to be percent-encoded.&lt;br /&gt;
&lt;br /&gt;
URIs that differ only by whether an unreserved character is percent-encoded or appears literally are equivalent by definition, but URI processors, in practice, may not always recognize this equivalence. For example, URI consumers &amp;#039;&amp;#039;should not&amp;#039;&amp;#039; treat &amp;lt;code&amp;gt;%41&amp;lt;/code&amp;gt; differently from &amp;lt;code&amp;gt;A&amp;lt;/code&amp;gt; or &amp;lt;code&amp;gt;%7E&amp;lt;/code&amp;gt; differently from &amp;lt;code&amp;gt;~&amp;lt;/code&amp;gt;, but some do. For maximal interoperability, URI producers are discouraged from percent-encoding unreserved characters.&lt;br /&gt;
&lt;br /&gt;
=== Percent character&amp;lt;span class=&amp;quot;anchor&amp;quot; id=&amp;quot;Percent-encoding the percent character&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; ===&lt;br /&gt;
Because the percent character ( &amp;lt;code&amp;gt;%&amp;lt;/code&amp;gt; ) serves to indicate percent-encoded octets, it must itself be percent-encoded as &amp;lt;code&amp;gt;%25&amp;lt;/code&amp;gt; to be used as data within a URI.&lt;br /&gt;
&lt;br /&gt;
=== Arbitrary data&amp;lt;span class=&amp;quot;anchor&amp;quot; id=&amp;quot;Percent-encoding arbitrary data&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; ===&lt;br /&gt;
Most URI schemes involve the representation of arbitrary data, such as an [[IP address]] or [[file system]] path, as components of a URI. URI scheme specifications should, but often do not, provide an explicit mapping between URI characters and all possible data values being represented by those characters.&lt;br /&gt;
&lt;br /&gt;
==== Binary data ====&lt;br /&gt;
Since the publication of RFC 1738 in 1994 it has been specified that schemes that provide for the representation of [[binary data]] in a URI must divide the data into 8-bit bytes and percent-encode each byte in the same manner as above.{{Ref RFC|1738|section=2.2}}{{Ref RFC|2396|section=2.4}}{{Ref RFC|3986|section=1.2.1, 2.1, 2.5}} Byte value 0x0F, for example, should be represented by &amp;lt;code&amp;gt;%0F&amp;lt;/code&amp;gt;, but byte value 0x41 can be represented by &amp;lt;code&amp;gt;A&amp;lt;/code&amp;gt;, or &amp;lt;code&amp;gt;%41&amp;lt;/code&amp;gt;. The use of unencoded characters for alphanumeric and other unreserved characters is typically preferred, as it results in shorter URLs.&lt;br /&gt;
&lt;br /&gt;
==== Character data ====&lt;br /&gt;
The procedure for percent-encoding binary data has often been extrapolated, sometimes inappropriately or without being fully specified, to apply to character-based data. In the [[World Wide Web]]&amp;#039;s formative years, when dealing with data characters in the ASCII repertoire and using their corresponding bytes in ASCII as the basis for determining percent-encoded sequences, this practice was relatively harmless; it was just assumed that characters and bytes mapped one-to-one and were interchangeable. The need to represent characters outside the ASCII range, however, grew quickly, and URI schemes and protocols often failed to provide standard rules for preparing character data for inclusion in a URI. Web applications consequently began using different multi-byte, [[state (computer science)|stateful]], and other non-ASCII-compatible encodings as the basis for percent-encoding, leading to ambiguities and difficulty interpreting URIs reliably.&lt;br /&gt;
&lt;br /&gt;
For example, many URI schemes and protocols based on RFCs 1738 and 2396 presume that the data characters will be converted to bytes according to some unspecified [[character encoding]] before being represented in a URI by unreserved characters or percent-encoded bytes. If the scheme does not allow the URI to provide a hint as to what encoding was used, or if the encoding conflicts with the use of ASCII to percent-encode reserved and unreserved characters, then the URI cannot be reliably interpreted. Some schemes fail to account for encoding at all and instead just suggest that data characters map directly to URI characters, which leaves it up to implementations to decide whether and how to percent-encode data characters that are in neither the reserved nor unreserved sets.&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|+ Common characters after percent-encoding (ASCII or UTF-8 based)&lt;br /&gt;
|- align=&amp;quot;center&amp;quot;&lt;br /&gt;
|&amp;lt;code&amp;gt;[[Space (punctuation)|␣]]&amp;lt;/code&amp;gt;&lt;br /&gt;
|&amp;lt;code&amp;gt;[[Double quote|&amp;quot;]]&amp;lt;/code&amp;gt;&lt;br /&gt;
|&amp;lt;code&amp;gt;[[Percent sign|%]]&amp;lt;/code&amp;gt;&lt;br /&gt;
| &amp;lt;code&amp;gt;[[hyphen|-]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[full stop|.]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[angle bracket|&amp;lt;]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[angle bracket|&amp;gt;]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[back slash|\]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[caret|^]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[underscore|_]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[grave accent|`]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[curly bracket|{]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[vertical bar|&amp;lt;nowiki&amp;gt;|&amp;lt;/nowiki&amp;gt;]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[curly bracket|}]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[tilde|~]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[£]]&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;[[€]]&amp;lt;/code&amp;gt; &lt;br /&gt;
|- align=&amp;quot;center&amp;quot; valign=&amp;quot;top&amp;quot;&lt;br /&gt;
|&amp;lt;code&amp;gt;%20&amp;lt;/code&amp;gt;&lt;br /&gt;
|&amp;lt;code&amp;gt;%22&amp;lt;/code&amp;gt;&lt;br /&gt;
|&amp;lt;code&amp;gt;%25&amp;lt;/code&amp;gt;&lt;br /&gt;
| &amp;lt;code&amp;gt;%2D&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;%2E&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;%3C&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;%3E&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;%5C&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;%5E&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;%5F&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;%60&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;%7B&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;%7C&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;%7D&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;%7E&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;%C2%A3&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;%E2%82%AC&amp;lt;/code&amp;gt;&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Arbitrary character data is sometimes percent-encoded and used in non-URI situations, such as for password-obfuscation programs or other system-specific translation protocols.&lt;br /&gt;
&lt;br /&gt;
=== Current standard ===&lt;br /&gt;
{{main article|Internationalized Resource Identifier}}&lt;br /&gt;
The generic URI syntax recommends that new URI schemes that provide for the representation of character data in a URI should, in effect, represent characters from the unreserved set without translation and should convert all other characters to bytes according to [[UTF-8]], and then percent-encode those values. This suggestion was introduced in January 2005 with the publication of RFC 3986. URI schemes introduced before this date are not affected.&lt;br /&gt;
&lt;br /&gt;
Not addressed by the current specification is what to do with encoded character data. For example, in computers, character data manifests in encoded form, at some level, and thus could be treated as either binary or character data when being mapped to URI characters. Presumably, it is up to the URI scheme specifications to account for this possibility and require one or the other, but in practice, few, if any, actually do.&lt;br /&gt;
&lt;br /&gt;
=== Non-standard implementations ===&lt;br /&gt;
There exists a non-standard encoding for Unicode characters: &amp;lt;code&amp;gt;%u&amp;#039;&amp;#039;xxxx&amp;#039;&amp;#039;&amp;lt;/code&amp;gt;, where &amp;#039;&amp;#039;xxxx&amp;#039;&amp;#039; is a [[UTF-16]] code unit represented as four hexadecimal digits. For example, the 13th edition of [[ECMA-262]] includes an &amp;lt;code&amp;gt;escape&amp;lt;/code&amp;gt; function that uses this syntax.&amp;lt;ref&amp;gt;{{cite web |title=ECMAScript 2017 Language Specification (ECMA-262, 8th edition, June 2017) |url=https://www.ecma-international.org/ecma-262/8.0/index.html |url-status=live |archive-url=https://web.archive.org/web/20180702045054/http://www.ecma-international.org/ecma-262/8.0/index.html |archive-date=2 July 2018 |access-date=20 June 2018 |publisher=Ecma International}}&amp;lt;/ref&amp;gt; However, this behavior is not specified by any RFC, and has been rejected by the W3C.&amp;lt;ref&amp;gt;{{cite web |last1=Duerst |first1=Martin |last2=Suignard |first2=Michel |date=30 November 2004 |title=Internationalized Resource Identifiers (IRIs) |url=https://www.w3.org/International/iri-edit/draft-duerst-iri.html |access-date=17 September 2025 |website=w3.org}}&amp;lt;/ref&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== The application/x-www-form-urlencoded type ==&lt;br /&gt;
&amp;lt;!-- [[application/x-www-form-urlencoded]] and [[x-www-form-urlencoded]] redirect to this section --&amp;gt;&lt;br /&gt;
When data that has been entered into HTML [[form (web)|form]]s is submitted, the form field names and values are encoded and sent to the server in an HTTP request message using method [[Hypertext Transfer Protocol#Request methods|GET]] or [[POST (HTTP)|POST]], or, historically, via [[email]].{{refn|group=nb|User-agent support for email based [[HyperText Markup Language|HTML]] form submission, using a &amp;#039;mailto&amp;#039; [[Uniform Resource Locator|URL]] as the form action, was proposed in {{IETF RFC|1867}} section 5.6, during the HTML 3.2 era. Various web browsers implemented it by invoking a separate email program or using their own rudimentary [[Simple Mail Transfer Protocol|SMTP]] capabilities. Although sometimes unreliable, it was briefly popular as a simple way to transmit form data without involving a web server or [[Common Gateway Interface|CGI]] scripts.}} The encoding used by default is based on an early version of the general URI percent-encoding rules,{{Ref RFC|1630}} with a number of modifications such as [[newline]] normalization and replacing spaces with &amp;lt;code&amp;gt;+&amp;lt;/code&amp;gt; instead of &amp;lt;code&amp;gt;%20&amp;lt;/code&amp;gt;. The [[media type]] of data encoded this way is &amp;lt;code&amp;gt;application/x-www-form-urlencoded&amp;lt;/code&amp;gt;, and it is currently defined in the HTML and [[XForms]] specifications. In addition, the [[Common Gateway Interface|CGI]] specification contains rules for how web servers decode data of this type and make it available to applications.&lt;br /&gt;
&lt;br /&gt;
When HTML form data is sent in an HTTP GET request, it is included in the [[query string|query component]] of the request URI using the same syntax described above. When sent in an HTTP [[POST (HTTP)|POST]] request or via email, the data is placed in the body of the message, and &amp;lt;code&amp;gt;application/x-www-form-urlencoded&amp;lt;/code&amp;gt; is included in the message&amp;#039;s Content-Type header.&lt;br /&gt;
&amp;lt;!-- discuss this media type, including how it is underspecified and outdated, how it differs from current standards, and how it has been implemented in web browsers for submitting HTML form data using the encoding of the HTML document containing the form (or user override) as the basis for percent-encoding, and workarounds used for unencodable characters --&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== See also ==&lt;br /&gt;
{{Wikifunctions|Z10761|URI percent encode}}&lt;br /&gt;
{{Wikifunctions|Z10774|URI percent decode}}&lt;br /&gt;
&lt;br /&gt;
* {{Annotated link |Base64}}&lt;br /&gt;
* {{Annotated link |Binary-to-text encoding}}&lt;br /&gt;
* {{Annotated link |Internationalized Resource Identifier}}&lt;br /&gt;
* {{Annotated link |Punycode}}&lt;br /&gt;
* {{Annotated link |Shellcode}}&lt;br /&gt;
&lt;br /&gt;
== Notes ==&lt;br /&gt;
{{reflist|group=nb}}&lt;br /&gt;
&lt;br /&gt;
== References ==&lt;br /&gt;
{{reflist}}&lt;br /&gt;
&lt;br /&gt;
== External links ==&lt;br /&gt;
The following specifications all discuss and define reserved characters, unreserved characters, and percent-encoding, in some form or other:&lt;br /&gt;
* {{IETF RFC|3986|link=no}} / [[Internet standard|STD]] {{Cite IETF |std=66}} (plus [http://www.rfc-editor.org/errata_search.php?rfc=3986 errata]), the current generic URI syntax specification.&lt;br /&gt;
* {{IETF RFC|2396|link=no}} (obsolete, plus [http://www.rfc-editor.org/errata_search.php?rfc=2396&amp;amp;rec_status=15&amp;amp;presentation=records errata]) and {{IETF RFC|2732|link=no}} (plus [http://www.rfc-editor.org/errata_search.php?rfc=2732&amp;amp;rec_status=15&amp;amp;presentation=records errata]) together comprised the previous version of the generic URI syntax specification.&lt;br /&gt;
* {{IETF RFC|1738|link=no}} (mostly obsolete) and {{IETF RFC|1808|link=no}} (obsolete), which define [[Uniform Resource Locator|URLs]].&lt;br /&gt;
* {{IETF RFC|1630|link=no}} (obsolete), the first generic URI syntax specification.&lt;br /&gt;
* {{cite web |title=Naming and Addressing: URIs, URLs, ... |url=http://www.w3.org/Addressing/ |access-date=17 September 2025 |publisher=W3C}} (guideline)&lt;br /&gt;
* {{cite web |title=URI encoding programs |url=http://www.w3.org/International/O-URL-code.html |access-date=17 September 2025 |publisher=W3C}} (W3C explanation of UTF-8 in URIs, the page is no longer maintained and may be inaccurate)&lt;br /&gt;
* {{cite web |title=Forms |url=https://www.w3.org/TR/html4/interact/forms.html#h-17.13.4.1 |access-date=17 September 2025 |publisher=W3C}} (W3C HTML form content types)&lt;br /&gt;
&lt;br /&gt;
[[Category:URI schemes]]&lt;br /&gt;
[[Category:Internet Standards]]&lt;br /&gt;
[[Category:Binary-to-text encoding formats]]&lt;/div&gt;</summary>
		<author><name>Admin</name></author>
	</entry>
</feed>