Character Encoding Quick Guide

 
 
Encoding defines how the values of certain characters are represented, in terms of bits. Examples:
  • ASCII (American Standard Code for Information Interchange), a 7-bit character set.
  • ISO-8859-1, a 8-bit character set.
  • Unicode, a 16-bit character set.


rss feed

Quick reference






ASCII.




ANSI is a standards body and their best-known encoding is ASCII. ASCII is a 7-bit encoding, covering values from 0 to 127.

Character ranges 0-31 decimal and 127 decimal are control characters and are not printable.

To add the [ character in HTML, type:
  • &#decimal_value;

    For example: [    

  • &#xhex_value;

    For example: [


Decimal Hex Unicode Description Character Entity Name Key
000 00 0000 null [nul]   Ctrl-@
001 01 0001 start of heading [soh]   Ctrl-A
002 02 0002 start of text [stx]   Ctrl-B
003 03 0003 end of text [etx]   Ctrl-C
004 04 0004 end of transmission [eot]   Ctrl-D
005 05 0005 enquiry [enq]   Ctrl-E
006 06 0006 acknowledge [ack]   Ctrl-F
007 07 0007 bell [bel]   Ctrl-G
008 08 0008 backspace [bs]   Ctrl-H
009 09 0009 horizontal tab [ht]   Ctrl-I
010 0A 000A new line, line feed [nl]   Ctrl-J
011 0B 000B vertical tab [vt]   Ctrl-K
012 0C 000C form feed, new page [ff]   Ctrl-L
013 0D 000D carriage return [cr]   Ctrl-M
014 0E 000E shift out [so]   Ctrl-N
015 0F 000F shift in [si]   Ctrl-O
016 10 0010 data link escape [dle]   Ctrl-P
017 11 0011 device control 1 [dc1]   Ctrl-Q
018 12 0012 device control 2 [dc2]   Ctrl-R
019 13 0013 device control 3 [dc3]   Ctrl-S
020 14 0014 device control 4 [dc4]   Ctrl-T
021 15 0015 negative acknowledge [nak]   Ctrl-U
022 16 0016 synchronous idle [syn]   Ctrl-V
023 17 0017 end of trans. block [etb]   Ctrl-W
024 18 0018 cancel [can]   Ctrl-X
025 19 0019 end of medium [em]   Ctrl-Y
026 1A 001A substitute [sub]   Ctrl-Z
027 1B 001B escape [esc]   Ctrl-[
028 1C 001C file separator [fs]   Ctrl-\
029 1D 001D group separator [gs]   Ctrl-]
030 1E 001E record separator [rs]   Ctrl-^
031 1F 001F unit separator [us]   Ctrl-_
032 20 0020 Space Space    
033 21 0021 Exclamation mark !    
034 22 0022 quotation mark " "  
035 23 0023 Number sign #    
036 24 0024 Dollar sign $    
037 25 0025 Percent sign %    
038 26 0026 Ampersand & &  
039 27 0027 Apostrophe '    
040 28 0028 Left parenthesis (    
041 29 0029 Right parenthesis )    
042 2A 002A Asterisk *    
043 2B 002B Plus sign +    
044 2C 002C Comma ,    
045 2D 002D Hyphen -    
046 2E 002E Period (fullstop) .    
047 2F 002F Solidus (slash) /    
048 30 0030 0 0    
049 31 0031 1 1    
050 32 0032 2 2    
051 33 0033 3 3    
052 34 0034 4 4    
053 35 0035 5 5    
054 36 0036 6 6    
055 37 0037 7 7    
056 38 0038 8 8    
057 39 0039 9 9    
058 3A 003A Colon :    
059 3B 003B Semi-colon ;    
060 3C 003C less-than sign < &lt;  
061 3D 003D Equals sign =    
062 3E 003E greater-than sign > &gt;  
063 3F 003F Question mark ?    
064 40 0040 Commercial at @    
065 41 0041 A A    
066 42 0042 B B    
067 43 0043 C C    
068 44 0044 D D    
069 45 0045 E E    
070 46 0046 F F    
071 47 0047 G G    
072 48 0048 H H    
073 49 0049 I I    
074 4A 004A J J    
075 4B 004B K K    
076 4C 004C L L    
077 4D 004D M M    
078 4E 004E N N    
079 4F 004F O O    
080 50 0050 P P    
081 51 0051 Q Q    
082 52 0052 R R    
083 53 0053 S S    
084 54 0054 T T    
085 55 0055 U U    
086 56 0056 V V    
087 57 0057 W W    
088 58 0058 X X    
089 59 0059 Y Y    
090 5A 005A Z Z    
091 5B 005B Left square bracket [    
092 5C 005C Reverse solidus (backslash) \    
093 5D 005D Right square bracket ]    
094 5E 005E Caret ^    
095 5F 005F Horizontal bar (underscore) _    
096 60 0060 Acute accent `    
097 61 0061 a a    
098 62 0062 b b    
099 63 0063 c c    
100 64 0064 d d    
101 65 0065 e e    
102 66 0066 f f    
103 67 0067 g g    
104 68 0068 h h    
105 69 0069 i i    
106 6A 006A j j    
107 6B 006B k k    
108 6C 006C l l    
109 6D 006D m m    
110 6E 006E n n    
111 6F 006F o o    
112 70 0070 p p    
113 71 0071 q q    
114 72 0072 r r    
115 73 0073 s s    
116 74 0074 t t    
117 75 0075 u u    
118 76 0076 v v    
119 77 0077 w w    
120 78 0078 x x    
121 79 0079 y y    
122 7A 007A z z    
123 7B 007B Left curly brace {    
124 7C 007C Vertical bar |    
125 7D 007D Right curly brace }    
126 7E 007E Tilde ~    
127 7F 007F delete [del]    


The ASCII character set in a text file.
The printable ASCII characters in a text file.