Code page 367
| Company type | Standard |
|---|---|
| Industry | Computer character encoding |
| Founded | 1963 |
| Founder | Bob Bemer and ASA X3.2 subcommittee |
| Headquarters | United States |
Area served | Worldwide |
| Products | Character encoding scheme |
| Owner | American National Standards Institute (ANSI) |
ASCII (), standing for American Standard Code for Information Interchange, is a character encoding scheme that includes 95 printable symbols and 33 control characters, totaling 128 unique code points. Its set of punctuation marks has had a profound impact on the syntax of programming languages and text markup conventions. ASCII laid the foundation for contemporary computer character sets, with Unicode’s initial 128 code points directly corresponding to ASCII.
Each ASCII code point is represented by a number between 0 and 127, encoded as a seven-bit binary number. Among these, 95 are visible characters such as digits (0–9), uppercase and lowercase alphabets (A–Z, a–z), and frequently used punctuation marks. For example, the lowercase letter corresponds to the decimal value 105. The standard also specifies 33 control codes originally intended for teleprinter operations; while many of these controls are now considered obsolete, carriage return, line feed, and tab remain in common use.
ASCII does not include characters with diacritical marks, which restricts its ability to directly represent words like résumé or jalapeño. In some systems, diacritics can be simulated by overstriking base characters with symbols such as backticks (`) or tildes (~).
The Internet Assigned Numbers Authority (IANA) refers to this encoding as US-ASCII. ASCII is acknowledged as an IEEE milestone due to its critical role in establishing computing standards.
History
ASCII originated as the standardization of a seven-bit teleprinter code derived from earlier telegraph code systems.
Development of the ASCII standard commenced in May 1961 when IBM engineer Bob Bemer introduced the concept to the American Standards Association’s (ASA, now American National Standards Institute or ANSI) X3.2 subcommittee. The initial version was released in 1963 in conjunction with the launch of the Teletype Model 33. The standard saw significant revisions in 1967 and several updates through to 1986. Unlike predecessors such as Baudot code, ASCII was engineered for straightforward collation—particularly alphabetical sorting—and incorporated control codes for devices beyond teleprinters.
The ASA's X3 committee, specifically its X3.2 (later renamed X3L2) subcommittee and X3.2.4 working group (currently INCITS), developed ASCII. The ASA evolved into the United States of America Standards Institute (USASI) before becoming ANSI.
Published as ASA X3.4-1963, ASCII included special characters and control codes while reserving 28 positions for future assignments and one control code left undefined. Initial discussions debated adding more control codes versus including lowercase letters; by May 1963, lowercase letters were allocated to bits 6 and 7, enabling them to differ from uppercase letters by only one bit—facilitating case-insensitive comparisons and simpler hardware design.
The X3 committee introduced additional symbols such as braces and vertical bars, renamed certain control codes (for example, changing SOM to SOH), and eliminated others like RU. Subsequent revisions appeared under USAS X3.4-1967, USAS X3.4-1968, ANSI X3.4-1977, and ANSI X3.4-1986.
The use of ASCII for Network Interchange was outlined in 1969 and officially designated as an Internet Standard in 2015.
Revisions
- ASA X3.4-1963
- ASA X3.4-1965 (approved but unpublished; utilized by IBM 2260, IBM 2265, and IBM 2848 Display Control)
- USAS X3.4-1967
- USAS X3.4-1968
- ANSI X3.4-1977
- ANSI X3.4-1986
- ANSI X3.4-1986 (R1992)
- ANSI X3.4-1986 (R1997)
- ANSI INCITS 4-1986 (R2002)
- ANSI INCITS 4-1986 (R2007)
- INCITS 4-1986 (R2012)
- INCITS 4-1986 (R2017)
- INCITS 4-1986 (R2022)
The X3.15 specification addressed ASCII data transmission using least significant bit first ordering and its recording on punched tape, proposing a nine-track magnetic tape format along with considerations for punched card media.
Bit width
The X3.2 subcommittee developed ASCII by building upon earlier teleprinter encoding schemes, establishing a system to translate digital bit sequences into characters, thus facilitating text processing and communication in digital devices. Previous encoding systems contained 26 letters, 10 numerals, and up to 25 special symbols, along with control characters compatible with the CCITT International Telegraph Alphabet No. 2 (ITA2) from 1932, FIELDATA (1956), and early EBCDIC (1963). These systems required more than 64 unique codes to function.
ITA2 was derived from the 5-bit Baudot code created by Émile Baudot in 1870.
During deliberations, the committee considered implementing a shift mechanism similar to ITA2’s approach to extend six-bit codes beyond 64 characters. However, this concept was dismissed due to concerns over transmission reliability; errors in shift signals could disrupt large portions of data. Consequently, ASCII was designed with a minimum of seven bits.
While an eight-bit code was proposed to enable efficient representation of two digits through binary-coded decimal, it was ultimately rejected to reduce transmission expenses. Seven bits were deemed sufficient, with the eighth bit on perforated tape optionally used for parity error checking. In eight-bit systems lacking parity checking, the eighth bit was generally set to zero.
Internal organization
ASCII’s structure separates control codes from graphic characters for clarity and ease of identification. The initial two "ASCII sticks" (comprising 32 positions) were allocated for control characters. The space character was positioned before graphic symbols at hexadecimal location 20 to facilitate sorting operations. Numerous special separator symbols were placed ahead of numeric digits. The committee emphasized support for an uppercase 64-character alphabet and designed ASCII so it could be readily reduced to a practical 64-character graphic subset, akin to DEC’s SIXBIT code from 1963. Lowercase letters were not interspersed with uppercase; instead, special and numeric codes preceded the letters, with 'A' located at hexadecimal 41, consistent with the British draft standard. Digits 0 through 9 are encoded with a prefix of 011 followed by bits corresponding directly to their binary values, simplifying binary-coded decimal conversions.
Non-alphanumeric characters were assigned positions reflecting their shifted counterparts on mechanical typewriters based on the Remington No. 2 model from 1878—the first machine featuring a shift key. Shifted symbols for digits 2 through 9 corresponded to characters such as !"#$%_&'(), reflecting early typewriter layouts where '0' and '1' were often omitted. In ASCII, the characters !"#$% occupy positions 1 through 5 in the second stick, aligning with digits 1 through 5 in the adjacent stick. Because space occupied the '0' position, parentheses could not align with '9' and '0', prompting adjustments like removing the underscore from position '6' and shifting other characters—similar to certain European typewriter layouts. This inconsistency influenced bit-paired keyboards such as the Teletype Model 33 to adopt ASCII’s left-shifted arrangement rather than traditional mechanical layouts.
Electric typewriters like IBM’s Selectric introduced a distinct layout starting in 1961 that became standard on computers after the IBM PC launch in 1981, particularly with Model M keyboards released in 1984. As a result, modern keyboard shift mappings differ from ASCII’s original assignments. The /? pair dates back to Remington No. 2, while ,< and .> pairs appeared on some keyboards; other models did not shift comma or period so uppercase input could be entered without releasing the shift key. ASCII also rearranged certain symbol pairs—for example, splitting ;: and modifying mathematical symbols from - * = + into : * ; + -=.
Several frequently used typewriter symbols were excluded from ASCII, including fractions like ½ and ¼ as well as the ¢ sign. Conversely, ^, `, and ~ were incorporated as diacritical marks intended for international use; < and > were added for mathematical notation alongside line-drawing characters \ and |. The '@' symbol—rare in continental Europe and anticipated to be replaced by accented À in French variants—was assigned hexadecimal position 40 immediately before 'A'.
Key control codes essential for data transmission included start of message (SOM), end of address (EOA), end of message (EOM), end of transmission (EOT), "who are you?" (WRU), "are you?" (RU), reserved device control (DC0), synchronous idle (SYNC), and acknowledge (ACK). These codes were arranged deliberately to maximize Hamming distance between their bit patterns to enhance error detection capabilities.
Character sorting
The ordering based on ASCII codes, often referred to as ASCIIbetical ordering, is occasionally employed for sorting data instead of the conventional alphabetical sequence. Notable distinctions include:
- Capital letters appear before lowercase ones (for instance, "Z" precedes "a")
- Numerals and numerous punctuation symbols are placed prior to letters
A hybrid method involves converting uppercase characters to lowercase prior to evaluating their ASCII values for comparison.
Character set
| Template:Chset-left1 | Template:Chset-ctrl1 | Template:Chset-ctrl1 | Template:Chset-ctrl1 | Template:Chset-ctrl1 | Template:Chset-ctrl1 | Template:Chset-ctrl1 | Template:Chset-ctrl1 | Template:Chset-ctrl1 | Template:Chset-ctrl1 | Template:Chset-ctrl1 | Template:Chset-ctrl1 | Template:Chset-ctrl1 | Template:Chset-ctrl1 | Template:Chset-ctrl1 | Template:Chset-ctrl1 | Template:Chset-ctrl1 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Template:Chset-left1 | Template:Chset-ctrl1 | Template:Chset-ctrl1 | Template:Chset-ctrl1 | Template:Chset-ctrl1 | Template:Chset-ctrl1 | Template:Chset-ctrl1 | Template:Chset-ctrl1 | Template:Chset-ctrl1 | Template:Chset-ctrl1 | Template:Chset-ctrl1 | Template:Chset-ctrl1 | Template:Chset-ctrl1 | Template:Chset-ctrl1 | Template:Chset-ctrl1 | Template:Chset-ctrl1 | Template:Chset-ctrl1 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Template:Chset-left1 | Template:Chset-ctrl1 | Template:Chset-cell1 | Template:Chset-cell1 | Template:Chset-cell1 | Template:Chset-cell1 | Template:Chset-cell1 | Template:Chset-cell1 | Template:Chset-cell1 | Template:Chset-cell1 | Template:Chset-cell1 | Template:Chset-cell1 | Template:Chset-cell1 | Template:Chset-cell1 | Template:Chset-cell1 | {{chset-cell1 } 46 U+002E}: FULL STOP }
{|
Control charactersThe initial 32 code points in ASCII (decimal 0–31), along with the final code (decimal 127), are designated as control characters. These codes are primarily used to manage peripheral devices like printers or to convey metadata about data streams, such as those recorded on magnetic tape. Although termed characters, they do not produce printable symbols. For debugging purposes, "placeholder" icons are assigned according to ISO 2047 standards. For instance, the code 0x0A corresponds to "line feed," which advances paper in printers, while code 8 represents "backspace." Non-whitespace control characters exclude carriage return, line feed, and whitespace. ASCII itself does not specify document formatting or structure; these responsibilities fall to other systems such as markup languages. The original ASCII specification used brief descriptive names for control characters, sometimes leading to ambiguity—both intentionally, when usage depended on context, and unintentionally due to vague definitions like that of "delete." The Teletype Model 33 ASR terminal played a major role in shaping the interpretation of control characters. This device included a paper tape reader and punch, widely used for program storage through the 1980s. Codes like 17 (control-Q, DC1/XON), 19 (control-S, DC3/XOFF), and 127 (delete) became de facto standards largely due to this terminal. The Model 33 also gave physical effect to control-G (code 7, BEL) by triggering a bell sound as an alert. Early timesharing systems adopted a nonstandard use of code 15 (control-O) as a command to "delete previous character," although this usage eventually disappeared. When the Teletype 33 ASR’s tape reader received control-S (XOFF), it halted operation; sending control-Q (XON) resumed it. This flow control mechanism evolved into a widely accepted "handshaking" protocol that prevents buffer overflow and continues to be utilized in many systems today. Some implementations keep control-S as the stop command but use a second control-S instead of control-Q to restart output. Moreover, the Model 33 assigned control-R (DC2) and control-T (DC4) for starting and stopping the tape punch; some keycaps were labeled TAPE and Delete vs backspaceSince the Teletype could not physically move its typehead backward, it lacked a dedicated key for sending BS (backspace). Instead, it featured a key marked , which sent code 127 (DEL). This key was used to correct errors on manually punched paper tape by overwriting all holes at the error location, effectively replacing it with a character ignored by the reader. Teletypes were frequently paired with Digital Equipment Corporation (DEC) computers, which interpreted the DEL character as an instruction to erase the previous character because of limited key availability. As a result, DEC video terminals typically sent DEL when pressing the "Backspace" key by default, while a distinct "Delete" key generated an escape sequence. Many other terminals used BS for backspace functionality. Early Unix tty drivers allowed only one character—either BS or DEL—to erase the previous input in canonical mode, creating ambiguity depending on terminal type. Contemporary shells such as ksh, bash, and zsh now support both inputs. The absence of BS from certain keyboards allowed Ctrl+H to be repurposed for other commands, including serving as the "help" prefix in GNU Emacs. EscapeInitially, the "escape" character (ESC, ASCII code 27) was created to enable the transmission of control characters as literal values, thereby initiating what is known as an "escape sequence." This mechanism is evident in URL encoding schemes and programming languages such as C. Its functionality has since undergone significant development. In modern usage, sending an ESC character to a terminal generally triggers a command sequence—frequently an "ANSI escape code" that starts with a "Control Sequence Introducer" ("CSI", "") as defined by ECMA-48 standards. Certain commands, including "Reset to Initial State" ("RIS", ""), do not require this introducer. On the other hand, when an ESC character is received from a terminal, it often acts as an out-of-band signal to exit modes or halt processes in text editors such as TECO and vi. Within graphical user interfaces and windowing environments, ESC typically functions to cancel or close the active application. End of lineThe historical ambiguity surrounding control characters complicated the transfer of "plain text" files between different systems, especially regarding newline representations. Teletypes necessitated both a "carriage return" (CR) to reposition the printhead and a "line feed" (LF) to advance the paper. This two-character line termination became standard in DEC operating systems (OS/8, RT-11, RSX-11, etc.) and was maintained for compatibility with subsequent terminal hardware. When Gary Kildall created CP/M, he incorporated command-line syntax inspired by DEC's RT-11. IBM's 1970s systems employed EBCDIC encoding tailored for punch cards and line printers, lacking CR/LF conventions. The CR-LF line-ending format entered IBM's PC DOS (also marketed as MS-DOS) through CP/M and was later adopted by Windows. The use of dual characters for line endings introduced complexity and potential confusion. To address this, systems like Multics adopted LF alone to signify line termination, with tty drivers converting LF into CRLF upon output. This approach influenced Unix, Unix-like operating systems, and Amiga. Conversely, early Apple platforms (Macintosh OS, Apple DOS, ProDOS) utilized CR exclusively but transitioned to LF with their Unix-based macOS. Networks such as the ARPANET linked heterogeneous systems with disparate newline conventions and character encodings. The Telnet protocol established an ASCII "Network Virtual Terminal" (NVT) model employing CR-LF sequences to unify communication across diverse platforms. The File Transfer Protocol mirrored this design for command exchanges and ASCII data transfers. These protocols introduce additional challenges for services like E-mail and the World Wide Web on systems that do not natively use CR-LF line endings. End of file/streamThe PDP-6 monitor and its PDP-10 successor TOPS-10 designated control-Z (SUB) as the end-of-file marker for terminal input. Operating systems such as CP/M managed file size in disk blocks and utilized control-Z to indicate the actual conclusion of text content. As a result, EOF became commonly associated with control-Z rather than SUBstitute. The end-of-text character (ETX), or control-C, was unsuitable for marking file ends; control-Z’s placement near the alphabet’s end made it a practical mnemonic. ETX is widely used to interrupt or terminate programs via keyboard commands. Unix terminal drivers employ the end-of-transmission character (EOT), or control-D, to signify the conclusion of input streams. In both C programming and Unix traditions, text strings are terminated by the null character; these null-terminated strings are often referred to as ASCIZ or ASCIIZ, where Z stands for "zero." Control code chart
Specialized devices may display these codes differently, utilizing formats like ISO 2047 symbols or hexadecimal representation. Printable characters chartWhen ASCII was standardized, the range from hexadecimal code 20 to 7E corresponds to visible symbols—letters, numbers, punctuation marks, and various signs—totaling ninety-five printable characters. The space character at hex 20 is unique; although it lacks a visible symbol, it is classified among printable characters rather than control codes. The character with code hex 7F is a control character named "delete" (DEL), which is non-printable. In earlier ASCII editions, the caret (code 5E hex) was represented by an upward arrow, and the underscore (5F hex) appeared as a left-pointing arrow. By the year 1968, these were revised, with compromises such as shaping the underscore to resemble a wedge that could also signify a left arrow to maintain some backward compatibility.
UsageASCII made its commercial debut in 1963 as a seven-bit teleprinter code implemented by American Telephone & Telegraph for its TWX (TeletypeWriter eXchange) network. Initially, TWX utilized the five-bit ITA2 code, which was also adopted by the competing Telex system. Key innovations such as the escape sequence were introduced by Bob Bemer. His British counterpart, Hugh McGregor Ross, played a significant role in promoting this development; according to Bemer, in Europe the code was originally referred to as the Bemer–Ross Code. Due to his pivotal role, Bemer is frequently recognized as "the father of ASCII". On March 11, 1968, US President Lyndon B. Johnson issued a directive requiring that all computers acquired by the United States Federal Government incorporate ASCII support. He stated:
ASCII maintained its position as the leading character encoding on the World Wide Web until December 2007, when UTF-8, which maintains backward compatibility with ASCII, overtook it in prevalence. Variants and derivationsAs computing technology expanded worldwide, various standards organizations and companies created numerous ASCII adaptations to accommodate non-English Roman alphabets. Some of these are known as "ASCII extensions," although this label is often broadly applied to all variants—even those that do not retain ASCII’s original 7-bit character set. These adaptations have sometimes been mistakenly referred to simply as ASCII. 7-bit codesFrom its inception, ASCII was designed to be one among several national versions of an international character coding standard. International standards such as ISO 646 (established in 1967) ratified character encodings nearly identical to ASCII but included additional characters to represent non-US symbols like the UK's pound sterling (£), exemplified by code page 1104. Most countries required customized versions of ASCII to support local languages and currency marks; for instance, Canada developed a variant incorporating French characters. Numerous countries created ASCII variants that added non-English letters (such as é, ñ, ß, Ł) and currency signs (£, ¥) by assigning local characters to code points reserved for "national use." However, because of the four-year interval between ASCII's release in 1963 and ISO's initial international recommendation in 1967, these national-use allocations became de facto standards globally. This situation caused confusion and interoperability issues when countries implemented differing character assignments. Like ASCII, ISO/IEC 646 is a 7-bit encoding without extra codes; consequently, identical code points could represent different characters depending on the country. Although escape sequences existed to specify national variants, they were seldom employed, making it difficult to identify which variant was in use and restricting text-processing systems to handling only one variant at a time. Since brackets and braces were reassigned in some national variants to accented letters, programmers working with these variants had to write code using unconventional characters. For example:
would be used instead of
To address this challenge, C trigraphs were introduced in ANSI C, but their late adoption coupled with inconsistent compiler support limited their widespread use. As a result, many developers continued using ASCII versions of brackets and braces even when mixing them within words in languages like Swedish or German. In Japan and Korea, it is common for a variation to display the backslash (hexadecimal 5C) as ¥ (Yen sign) or ₩ (Won sign). Hence, file paths such as C:\Users\Smith appear as C:¥Users¥Smith or C:₩Users₩Smith. In Europe, broadcast television subtitles employ teletext character sets—variants of ASCII—under standards like World System Teletext and DVB-TXT. Subtitles originally created for teletext and later converted into other formats remain constrained by these character sets. 8-bit codesWith the progression from early computing systems to 8-, 16-, 32-, and eventually 64-bit architectures, the 8-bit byte emerged as the standard unit for character storage in memory. This development allowed for extended versions of ASCII utilizing 8 bits, which maintained the original 7-bit character set while incorporating additional symbols beyond the initial 128. It is important to note that ASCII itself remained a seven-bit encoding; the term "extended ASCII" is informal and not officially recognized. Different nations created their own 8-bit ASCII adaptations to accommodate regional languages, such as ISCII for Indian scripts and VISCII for Vietnamese. Early personal computer manufacturers frequently implemented proprietary 8-bit extensions that included elements like box-drawing characters, semigraphics, and sprites for video games. In some cases, control characters were substituted with platform-specific icons. Other systems employed the extra bit for alternative purposes; for example, Atari’s ATASCII utilized it to toggle inverse video display. Most of these extensions trace back to ASCII-1967, although some character sets—like Commodore's PETSCII and Sharp MZ—are based on ASCII-1963. IBM introduced code page 437 for its PC line, replacing control codes with graphic symbols such as smiley faces and allocating additional graphical elements to the upper half of the character range. Digital Equipment Corporation designed the Multinational Character Set (DEC-MCS) for VT220 terminals with an emphasis on supporting multiple languages rather than graphics. Apple’s Mac OS Roman and Adobe’s PostScript Standard Encoding incorporated international letters and typographic glyphs instead of graphical symbols. The ISO/IEC 8859 series, which evolved from DEC-MCS, gained widespread adoption. Microsoft extended this standard with Windows-1252 by including essential typographic punctuation marks necessary for high-quality text output. For many years, ISO-8859-1, Windows-1252, and 7-bit ASCII dominated web content until UTF-8 overtook them around 2008. The ISO/IEC 4873 standard introduced an additional set of 32 control codes within the hexadecimal range 80–9F, thereby expanding ASCII into a fully 8-bit encoding system. UnicodeUnicode alongside the ISO/IEC 10646 Universal Character Set (UCS) provides a vastly larger repertoire of characters, and their encoding schemes have progressively supplanted ISO/IEC 8859 and ASCII in numerous applications. Unlike ASCII’s limitation to 128 characters, Unicode and UCS differentiate between unique character identifiers (code points) and their encoded forms, which can be represented using variable-length encodings such as UTF-8, UTF-16, or fixed-length formats like UTF-32. When Unicode was introduced in 1991, it incorporated the original ASCII set as its first 128 code points, preserving identical numerical values. This design guarantees that UTF-8 maintains backward compatibility with standard 7-bit ASCII—files containing solely ASCII characters are byte-for-byte identical in both encodings. Furthermore, forward compatibility is ensured because software that only recognizes traditional ASCII control characters and disregards bytes with the highest bit set will still preserve UTF-8 encoded data without alteration. See also
Further reading
External links
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||