HTML authors need to look up HTML character encodings frequently as some characters can not (or hard to) be typed out directly from the keyboard. If you would like not do the math and search, you may find the HTML symbols you want to use and its HTML code in Reference: Special HTML Characters.
Calculating the HTML character encoding from ASCII code
For example, we want to encode HTML character ‘[‘.
First, look up the ASCII Table and find:
091 133 0x5B 01011011 [ (left opening bracket)
The decimal value for ‘[‘ is 091. The the HTML character encoding for ‘[‘ is: [
The HTML Document Character Set
You can also simply look up the character from HTML character set tables, such as this one The HTML Document Character Set.