256 in binary
The decimal number 256 written in binary is 100000000. In hexadecimal it is 100, and in octal 400.
| Base | Value |
|---|---|
| Decimal (base 10) | 256 |
| Binary (base 2) | 100000000 |
| Hexadecimal (base 16) | 100 |
| Octal (base 8) | 400 |
How 256 converts to binary
Binary is base 2, so each place is worth twice the one to its right: 1, 2, 4, 8, 16, and so on. Adding up the place values that have a 1 gives back the decimal number:
256 = 256
That is why 256 in decimal is 100000000 in binary: it is exactly the set of powers of two that add up to 256. To get the hexadecimal form, group the bits into fours from the right and write each group as one hex digit, which gives 100.
Convert any number
Type any value and watch all three bases update live in the binary converter, or read the theory behind it in the lessons on binary numbers and hexadecimal.
Want to build the circuit that does this? Open the lab and wire up an adder, or follow the free course from a single transistor up to an 8-bit CPU.
Open the binary converter →Frequently asked
What is 256 in binary?
256 in binary is 100000000. That is the sum of the powers of two 256, which add up to 256.
What is 256 in hexadecimal?
256 in hexadecimal is 100. You get it by grouping the binary digits 100000000 into fours from the right and writing each group as one hex digit.
How many bits is 256?
256 needs 9 bits in binary (100000000). It fits in 16 bits (two bytes).