Decimal to Binary and Binary to Decimal Converter
Convert decimal numbers to binary numbers and binary numbers to decimal numbers, and learn more about these number systems.
For quick conversions, feel free to use the conversion table.
Published: February 19, 2024.
|
On This Page: |

Decimal to Binary and Binary to Decimal Calculators
Note: Conversions are possible only for integer numbers since converting "fractional parts" may be very challenging due to the nature of floating-point arithmetic and representation; there might be precision issues, especially with very long fractional parts, so to avoid such issues, these two converters are limited only to integer numbers.
| Binary to Decimal Conversion |
|
| Decimal to Binary Conversion |
|
Binary, Octal, Decimal, and Hexadecimal Numbers Conversion Table
The following conversion table contains binary, octal, decimal, and hexadecimal numbers for fast and easy conversion.
| Binary Numbers | Octal Numbers | Decimal Numbers | Hexadecimal Numbers |
| 00000000 | 0 | 0 | 0 |
| 00000001 | 1 | 1 | 1 |
| 00000010 | 2 | 2 | 2 |
| 00000011 | 3 | 3 | 3 |
| 00000100 | 4 | 4 | 4 |
| 00000101 | 5 | 5 | 5 |
| 00000110 | 6 | 6 | 6 |
| 00000111 | 7 | 7 | 7 |
| 00001000 | 10 | 8 | 8 |
| 00001001 | 11 | 9 | 9 |
| 00001010 | 12 | 10 | A |
| 00001011 | 13 | 11 | B |
| 00001100 | 14 | 12 | C |
| 00001101 | 15 | 13 | D |
| 00001110 | 16 | 14 | E |
| 00001111 | 17 | 15 | F |
| 00010000 | 20 | 16 | 10 |
| 00010001 | 21 | 17 | 11 |
| 00010010 | 22 | 18 | 12 |
| 00010011 | 23 | 19 | 13 |
| 00010100 | 24 | 20 | 14 |
| 00010101 | 25 | 21 | 15 |
| 00010110 | 26 | 22 | 16 |
| 00010111 | 27 | 23 | 17 |
| 00011000 | 30 | 24 | 18 |
| 00011001 | 31 | 25 | 19 |
| 00011010 | 32 | 26 | 1A |
| 00011011 | 33 | 27 | 1B |
| 00011100 | 34 | 28 | 1C |
| 00011101 | 35 | 29 | 1D |
| 00011110 | 36 | 30 | 1E |
| 00011111 | 37 | 31 | 1F |
| 00100000 | 40 | 32 | 20 |
| 00100001 | 41 | 33 | 21 |
| 00100010 | 42 | 34 | 22 |
| 00100011 | 43 | 35 | 23 |
| 00100100 | 44 | 36 | 24 |
| 00100101 | 45 | 37 | 25 |
| 00100110 | 46 | 38 | 26 |
| 00100111 | 47 | 39 | 27 |
| 00101000 | 50 | 40 | 28 |
| 00101001 | 51 | 41 | 29 |
| 00101010 | 52 | 42 | 2A |
| 00101011 | 53 | 43 | 2B |
| 00101100 | 54 | 44 | 2C |
| 00101101 | 55 | 45 | 2D |
| 00101110 | 56 | 46 | 2E |
| 00101111 | 57 | 47 | 2F |
| 00110000 | 60 | 48 | 30 |
| 00110001 | 61 | 49 | 31 |
| 00110010 | 62 | 50 | 32 |
| 00110011 | 63 | 51 | 33 |
| 00110100 | 64 | 52 | 34 |
| 00110101 | 65 | 53 | 35 |
| 00110110 | 66 | 54 | 36 |
| 00110111 | 67 | 55 | 37 |
| 00111000 | 70 | 56 | 38 |
| 00111001 | 71 | 57 | 39 |
| 00111010 | 72 | 58 | 3A |
| 00111011 | 73 | 59 | 3B |
| 00111100 | 74 | 60 | 3C |
| 00111101 | 75 | 61 | 3D |
| 00111110 | 76 | 62 | 3E |
| 00111111 | 77 | 63 | 3F |
| 01000000 | 100 | 64 | 40 |
| 01000001 | 101 | 65 | 41 |
| 01000010 | 102 | 66 | 42 |
| 01000011 | 103 | 67 | 43 |
| 01000100 | 104 | 68 | 44 |
| 01000101 | 105 | 69 | 45 |
| 01000110 | 106 | 70 | 46 |
| 01000111 | 107 | 71 | 47 |
| 01001000 | 110 | 72 | 48 |
| 01001001 | 111 | 73 | 49 |
| 01001010 | 112 | 74 | 4A |
| 01001011 | 113 | 75 | 4B |
| 01001100 | 114 | 76 | 4C |
| 01001101 | 115 | 77 | 4D |
| 01001110 | 116 | 78 | 4E |
| 01001111 | 117 | 79 | 4F |
| 01010000 | 120 | 80 | 50 |
| 01010001 | 121 | 81 | 51 |
| 01010010 | 122 | 82 | 52 |
| 01010011 | 123 | 83 | 53 |
| 01010100 | 124 | 84 | 54 |
| 01010101 | 125 | 85 | 55 |
| 01010110 | 126 | 86 | 56 |
| 01010111 | 127 | 87 | 57 |
| 01011000 | 130 | 88 | 58 |
| 01011001 | 131 | 89 | 59 |
| 01011010 | 132 | 90 | 5A |
| 01011011 | 133 | 91 | 5B |
| 01011100 | 134 | 92 | 5C |
| 01011101 | 135 | 93 | 5D |
| 01011110 | 136 | 94 | 5E |
| 01011111 | 137 | 95 | 5F |
| 01100000 | 140 | 96 | 60 |
| 01100001 | 141 | 97 | 61 |
| 01100010 | 142 | 98 | 62 |
| 01100011 | 143 | 99 | 63 |
| 01100100 | 144 | 100 | 64 |
| 01100101 | 145 | 101 | 65 |
| 01100110 | 146 | 102 | 66 |
| 01100111 | 147 | 103 | 67 |
| 01101000 | 150 | 104 | 68 |
| 01101001 | 151 | 105 | 69 |
| 01101010 | 152 | 106 | 6A |
| 01101011 | 153 | 107 | 6B |
| 01101100 | 154 | 108 | 6C |
| 01101101 | 155 | 109 | 6D |
| 01101110 | 156 | 110 | 6E |
| 01101111 | 157 | 111 | 6F |
| 01110000 | 160 | 112 | 70 |
| 01110001 | 161 | 113 | 71 |
| 01110010 | 162 | 114 | 72 |
| 01110011 | 163 | 115 | 73 |
| 01110100 | 164 | 116 | 74 |
| 01110101 | 165 | 117 | 75 |
| 01110110 | 166 | 118 | 76 |
| 01110111 | 167 | 119 | 77 |
| 01111000 | 170 | 120 | 78 |
| 01111001 | 171 | 121 | 79 |
| 01111010 | 172 | 122 | 7A |
| 01111011 | 173 | 123 | 7B |
| 01111100 | 174 | 124 | 7C |
| 01111101 | 175 | 125 | 7D |
| 01111110 | 176 | 126 | 7E |
| 01111111 | 177 | 127 | 7F |
| 10000000 | 200 | 128 | 80 |
| 10000001 | 201 | 129 | 81 |
| 10000010 | 202 | 130 | 82 |
| 10000011 | 203 | 131 | 83 |
| 10000100 | 204 | 132 | 84 |
| 10000101 | 205 | 133 | 85 |
| 10000110 | 206 | 134 | 86 |
| 10000111 | 207 | 135 | 87 |
| 10001000 | 210 | 136 | 88 |
| 10001001 | 211 | 137 | 89 |
| 10001010 | 212 | 138 | 8A |
| 10001011 | 213 | 139 | 8B |
| 10001100 | 214 | 140 | 8C |
| 10001101 | 215 | 141 | 8D |
| 10001110 | 216 | 142 | 8E |
| 10001111 | 217 | 143 | 8F |
| 10010000 | 220 | 144 | 90 |
| 10010001 | 221 | 145 | 91 |
| 10010010 | 222 | 146 | 92 |
| 10010011 | 223 | 147 | 93 |
| 10010100 | 224 | 148 | 94 |
| 10010101 | 225 | 149 | 95 |
| 10010110 | 226 | 150 | 96 |
| 10010111 | 227 | 151 | 97 |
| 10011000 | 230 | 152 | 98 |
| 10011001 | 231 | 153 | 99 |
| 10011010 | 232 | 154 | 9A |
| 10011011 | 233 | 155 | 9B |
| 10011100 | 234 | 156 | 9C |
| 10011101 | 235 | 157 | 9D |
| 10011110 | 236 | 158 | 9E |
| 10011111 | 237 | 159 | 9F |
| 10100000 | 240 | 160 | A0 |
| 10100001 | 241 | 161 | A1 |
| 10100010 | 242 | 162 | A2 |
| 10100011 | 243 | 163 | A3 |
| 10100100 | 244 | 164 | A4 |
| 10100101 | 245 | 165 | A5 |
| 10100110 | 246 | 166 | A6 |
| 10100111 | 247 | 167 | A7 |
| 10101000 | 250 | 168 | A8 |
| 10101001 | 251 | 169 | A9 |
| 10101010 | 252 | 170 | AA |
| 10101011 | 253 | 171 | AB |
| 10101100 | 254 | 172 | AC |
| 10101101 | 255 | 173 | AD |
| 10101110 | 256 | 174 | AE |
| 10101111 | 257 | 175 | AF |
| 10110000 | 260 | 176 | B0 |
| 10110001 | 261 | 177 | B1 |
| 10110010 | 262 | 178 | B2 |
| 10110011 | 263 | 179 | B3 |
| 10110100 | 264 | 180 | B4 |
| 10110101 | 265 | 181 | B5 |
| 10110110 | 266 | 182 | B6 |
| 10110111 | 267 | 183 | B7 |
| 10111000 | 270 | 184 | B8 |
| 10111001 | 271 | 185 | B9 |
| 10111010 | 272 | 186 | BA |
| 10111011 | 273 | 187 | BB |
| 10111100 | 274 | 188 | BC |
| 10111101 | 275 | 189 | BD |
| 10111110 | 276 | 190 | BE |
| 10111111 | 277 | 191 | BF |
| 11000000 | 300 | 192 | C0 |
| 11000001 | 301 | 193 | C1 |
| 11000010 | 302 | 194 | C2 |
| 11000011 | 303 | 195 | C3 |
| 11000100 | 304 | 196 | C4 |
| 11000101 | 305 | 197 | C5 |
| 11000110 | 306 | 198 | C6 |
| 11000111 | 307 | 199 | C7 |
| 11001000 | 310 | 200 | C8 |
| 11001001 | 311 | 201 | C9 |
| 11001010 | 312 | 202 | CA |
| 11001011 | 313 | 203 | CB |
| 11001100 | 314 | 204 | CC |
| 11001101 | 315 | 205 | CD |
| 11001110 | 316 | 206 | CE |
| 11001111 | 317 | 207 | CF |
| 11010000 | 320 | 208 | D0 |
| 11010001 | 321 | 209 | D1 |
| 11010010 | 322 | 210 | D2 |
| 11010011 | 323 | 211 | D3 |
| 11010100 | 324 | 212 | D4 |
| 11010101 | 325 | 213 | D5 |
| 11010110 | 326 | 214 | D6 |
| 11010111 | 327 | 215 | D7 |
| 11011000 | 330 | 216 | D8 |
| 11011001 | 331 | 217 | D9 |
| 11011010 | 332 | 218 | DA |
| 11011011 | 333 | 219 | DB |
| 11011100 | 334 | 220 | DC |
| 11011101 | 335 | 221 | DD |
| 11011110 | 336 | 222 | DE |
| 11011111 | 337 | 223 | DF |
| 11100000 | 340 | 224 | E0 |
| 11100001 | 341 | 225 | E1 |
| 11100010 | 342 | 226 | E2 |
| 11100011 | 343 | 227 | E3 |
| 11100100 | 344 | 228 | E4 |
| 11100101 | 345 | 229 | E5 |
| 11100110 | 346 | 230 | E6 |
| 11100111 | 347 | 231 | E7 |
| 11101000 | 350 | 232 | E8 |
| 11101001 | 351 | 233 | E9 |
| 11101010 | 352 | 234 | EA |
| 11101011 | 353 | 235 | EB |
| 11101100 | 354 | 236 | EC |
| 11101101 | 355 | 237 | ED |
| 11101110 | 356 | 238 | EE |
| 11101111 | 357 | 239 | EF |
| 11110000 | 360 | 240 | F0 |
| 11110001 | 361 | 241 | F1 |
| 11110010 | 362 | 242 | F2 |
| 11110011 | 363 | 243 | F3 |
| 11110100 | 364 | 244 | F4 |
| 11110101 | 365 | 245 | F5 |
| 11110110 | 366 | 246 | F6 |
| 11110111 | 367 | 247 | F7 |
| 11111000 | 370 | 248 | F8 |
| 11111001 | 371 | 249 | F9 |
| 11111010 | 372 | 250 | FA |
| 11111011 | 373 | 251 | FB |
| 11111100 | 374 | 252 | FC |
| 11111101 | 375 | 253 | FD |
| 11111110 | 376 | 254 | FE |
| 11111111 | 377 | 255 | FF |
Guide to Converting Decimal Numbers to Binary Numbers
Converting decimal numbers to binary numbers is a foundational skill in computer science, electronics, and various fields of engineering.
The decimal system (base 10) is the numerical system most used by people, characterized by ten digits from 0 to 9. The binary system (base 2), on the other hand, uses only two digits, 0 and 1.
Each digit in a binary number represents a power of 2, with the rightmost digit representing 20, the next digit to the left representing 21, and so on.
Step-by-Step Conversion Process
- Find the Largest Power of 2: Start by finding the largest power of 2 that fits into the decimal number you are converting.
- Subtract to Find the Remainder: Subtract that value from your original number to find the remainder.
- Repeat for the Remainder: Repeat the process for the remainder: find the largest power of 2 that fits into it, subtract to find the new remainder, and continue until the remainder is 0.
- Write Down the Binary Number: For each power of 2 that you used, write down "1". For each power of 2 that did not fit, write down "0". Start with the highest power of 2 you tested and work your way down to 20.
Example Conversions
Example 1: Converting 13 Decimal to Binary
- The largest power of 2 that fits into 13 is 8 (23).
- Subtract 8 from 13 to get a remainder of 5.
- The largest power of 2 that fits into 5 is 4 (22).
- Subtract 4 from 5 to get a remainder of 1.
- The largest power of 2 that fits into 1 is 1 (20).
- There's no remainder.
Writing down the powers of 2 that fit, we get 1 for 23, 1 for 22, 0 for 21 (since 2 does not fit into our number at any step), and 1 for 20.
Thus, 13 in binary is 1101.
Example 2: Converting 9 Decimal to Binary
- The largest power of 2 that fits into 9 is 8 (23).
- Subtract 8 from 9 to get a remainder of 1.
- The next largest power of 2 (22) does not fit into 1, so we skip it.
- The largest power of 2 that fits into the remainder 1 is 1 (20).
For 9, the binary representation starts with 1 for 23, then 0 for 22 since it doesn't fit, 0 for 21 since it also doesn't fit, and finally, 1 for 20.
Therefore, 9 in binary is 1001.
Example 3: Converting 31 Decimal to Binary
- The largest power of 2 that fits into 31 is 16 (24).
- Subtract 16 from 31 to get a remainder of 15.
- The process continues with 8 (23), 4 (22), 2 (21), and 1 (20), all fitting into the remainder sequentially with no remainder left.
For 31, every power of 2 from 24 down to 20 fits into it exactly once, so 31 decimal is 11111 binary.
Guide to Converting Binary Numbers to Decimal Numbers
Converting binary numbers to decimal numbers is an essential skill in various fields of science and technology.
Binary, or base-2, is a numeral system that uses only two digits, 0 and 1, to represent numbers. Decimal, or base-10, is the numerical system most commonly used by people and uses ten digits, from 0 to 9. Each position in a binary number represents a power of 2, starting from 20 at the rightmost position.
Understanding how to convert from binary to decimal is crucial for working with digital systems, electronics, and computer programming.
Step-by-Step Conversion Process
- List the Powers of 2: Write down the powers of 2, starting from 20, increasing from right to left for each digit in your binary number. The rightmost digit corresponds to 20, the next digit to the left is 21, then 22, and so on.
- Multiply Each Binary Digit by Its Power of 2: For each digit in your binary number, multiply the digit (0 or 1) by its corresponding power of 2. If the digit is 0, the product is 0. If the digit is 1, the product is the power of 2 itself.
- Add the Products Together: Sum all the products you calculated in the previous step. The total is the decimal equivalent of your binary number.
Example Conversions
Example 1: Converting 1101 to Decimal
Consider the binary number 1101. From right to left, the powers of 2 corresponding to each digit are 20, 21, 22, and 23.
- 1 × 23 = 8
- 1 × 22 = 4
- 0 × 21 = 0 (this step results in 0 because the digit is 0)
- 1 × 20 = 1
Adding these products together, 8 + 4 + 0 + 1 = 13. Thus, the binary number 1101 is equivalent to the decimal number 13.
Example 2: Converting 1001 to Decimal
Let's convert the binary number 1001 to decimal.
- 1 × 23 = 8
- 0 × 22 = 0
- 0 × 21 = 0
- 1 × 20 = 1
Summing these products, 8 + 0 + 0 + 1 = 9. Therefore, the binary number 1001 converts to the decimal number 9.
Example 3: Converting 11111 to Decimal
For the binary number 11111, we apply the same method.
- 1 × 24 = 16
- 1 × 23 = 8
- 1 × 22 = 4
- 1 × 21 = 2
- 1 × 20 = 1
Adding these together, 16 + 8 + 4 + 2 + 1 = 31. So, the binary number 11111 is equivalent to the decimal number 31.
Brief History of Binary and Decimal Number Systems
The binary and decimal number systems are foundational to the understanding and development of mathematics, science, and technology.
These systems have enabled advancements in various fields, from computing to telecommunications, and their histories provide fascinating insights into human ingenuity and our relentless pursuit of knowledge and efficiency.
Origins of the Decimal System
The decimal number system, also known as the base-10 system, has its origins deeply rooted in ancient civilizations, with its widespread use being attributed to its natural fit with human anatomy – ten fingers for counting.

Historical evidence suggests that as far back as 3000 BCE, the Egyptians used a decimal system for their mathematics and commerce.
Similarly, the Indus Valley Civilization, which flourished around the same period, also demonstrated knowledge of a decimal system through their weights and measures.
The true power of the decimal system, however, was unleashed with the introduction of the concept of zero and place value. The ancient Indians played a crucial role in this development.
The work of mathematicians like Brahmagupta in the 7th century CE laid down the rules for arithmetic operations with zero. The system was further refined and spread throughout the world, including the Middle East and Europe, through the works of Islamic scholars during the medieval period, notably by Al-Khwarizmi in the 9th century.
The Binary System: A Discovery Spanning Centuries
The binary system, or base-2 number system, operates under a simple principle: it uses only two digits, 0 and 1, to represent numbers. The origins of binary can be traced back to ancient cultures, but its mathematical development is credited to several key figures over the centuries.
One of the earliest known discussions of the binary system was by the Indian scholar Pingala, in his work on Sanskrit prosody called Chandaḥśāstra (the Art of Poetry), dated around the 2nd century BCE. Pingala used binary numbers in the form of short and long syllables, a form of binary notation.
The significant leap in understanding and applying the binary system came from the West.
German mathematician and philosopher Gottfried Wilhelm Leibniz published a comprehensive account of binary numbers in the 17th century. Inspired by the I Ching from Chinese philosophy, which used a binary system of yin and yang, Leibniz saw the potential of binary for the development of mathematics and logic.
Leibniz's work laid the groundwork for the binary system's role in modern computing.
It wasn't until the 20th century, with the advent of digital electronics and computers, that binary found its place as the fundamental language of computers.
British mathematician and logician George Boole developed Boolean algebra in the mid-19th century, which used binary values to represent logical operations. This system was instrumental in the development of electronic circuits and computer logic.
Impact and Legacy
The decimal and binary systems have both shaped the world in profound ways. The decimal system's influence is seen in global commerce, science, and everyday life. Its universality and simplicity have made it the standard for numerical representation.
The binary system, on the other hand, has become the backbone of the digital age. Every piece of digital technology, from the simplest calculator to the most complex supercomputer, relies on binary code to operate. The system's simplicity allows for the reliable and efficient processing of data, making it ideal for electronic circuits.