Using the converter
Type a binary number, made of 0s and 1s, and its decimal value appears as you type. Several numbers can go in at once, separated by spaces, commas or new lines. Prefixes like 0x and 0b are fine, and so is the _ character used to group digits, as in 1001_1100. Numbers can be as long as you like and can be negative, but they have to be whole: there's no decimal point.
This converts numbers. To turn binary back into letters and words, use the binary translator instead.
Show the steps opens the working under the answer, line by line, the same way you'd set it out on paper. It shows the first four numbers when there are several.
How to convert binary to decimal
Write the place values over the bits, starting from 1 on the right and doubling each time: 1, 2, 4, 8, 16, 32, 64, 128. Add up the place values that have a 1 under them and skip the ones with a 0.
For 10011100 the 1s sit under 128, 16, 8 and 4. 128 + 16 + 8 + 4 is 156.
File permissions in octal
Unix file permissions are three bits each, one bit for read, one for write and one for execute, which is why they're written in octal. Read is worth 4, write 2 and execute 1, and each octal digit adds up one set, for the file's owner, its group and everyone else in turn. A mode of 754 gives the owner 4 + 2 + 1, everything, the group 4 + 1, read and execute, and everyone else 4, read only.
Decimal, binary, octal and hex from 0 to 32
| Decimal | Binary | Octal | Hex |
|---|---|---|---|
| 0 | 0 | 0 | 0 |
| 1 | 1 | 1 | 1 |
| 2 | 10 | 2 | 2 |
| 3 | 11 | 3 | 3 |
| 4 | 100 | 4 | 4 |
| 5 | 101 | 5 | 5 |
| 6 | 110 | 6 | 6 |
| 7 | 111 | 7 | 7 |
| 8 | 1000 | 10 | 8 |
| 9 | 1001 | 11 | 9 |
| 10 | 1010 | 12 | A |
| 11 | 1011 | 13 | B |
| 12 | 1100 | 14 | C |
| 13 | 1101 | 15 | D |
| 14 | 1110 | 16 | E |
| 15 | 1111 | 17 | F |
| 16 | 10000 | 20 | 10 |
| 17 | 10001 | 21 | 11 |
| 18 | 10010 | 22 | 12 |
| 19 | 10011 | 23 | 13 |
| 20 | 10100 | 24 | 14 |
| 21 | 10101 | 25 | 15 |
| 22 | 10110 | 26 | 16 |
| 23 | 10111 | 27 | 17 |
| 24 | 11000 | 30 | 18 |
| 25 | 11001 | 31 | 19 |
| 26 | 11010 | 32 | 1A |
| 27 | 11011 | 33 | 1B |
| 28 | 11100 | 34 | 1C |
| 29 | 11101 | 35 | 1D |
| 30 | 11110 | 36 | 1E |
| 31 | 11111 | 37 | 1F |
| 32 | 100000 | 40 | 20 |
Decimal, binary, octal and hex from 0 to 32stringmash.com/binary-to-decimal
Questions
What is 11111111 in decimal?
255, which is 128 + 64 + 32 + 16 + 8 + 4 + 2 + 1. It's the largest number a byte can hold.
Why is binary used in computers?
Each bit only has to be one of two states, on or off, which is simple to build reliably in electronics.
Does it handle spaces between groups of bits?
A space starts a new number, so 1001 1100 is read as two numbers. To group the bits of one number, join the groups with _ instead, as in 1001_1100.






