Each octet is made up of 8 bits and each bit has a value, either 0 or 1. The four groups of 8 bits have the same set of valid values in the range of 0 to 255 inclusive. The value of each bit placement, from right to left is 1, 2, 4, 8, 16, 32, 64, and 128.
Determine the value of the octet by adding the values of positions wherever there is a binary 1 present.
- If there is a 0 in a position, do not add the value.
- If all 8 bits are 0s, 00000000, the value of the octet is 0.
- If all 8 bits are 1s, 11111111, the value of the octet is 255 (128+64+32+16+8+4+2+1)
- If the 8 bits are mixed, the values are added together. For example, the octet 00100111 has a value of 39 (32+4+2+1).
So the value of each of the four octets can range from 0 to a maximum of 255.
Using the 32-bit IPv4 address, 11000000101010000000101000001010, convert the binary representation to dotted decimal using the following steps:
Step 1. Divide the 32 bits into 4 octets.
Step 2. Convert each octet to decimal.
Step 3. Add a "dot" between each decimal.
Click Play in the figure to see how a binary address is converted to dotted decimal.