How to convert bytes to bits
- Take the value in bytes.
- Use the formula bits = bytes × 8.
- For example, 1 B is 8 bit.
About bytes and bits
Multiply bytes by 8 to get bits. 4 bytes is 32 bits, 16 bytes is 128 bits and 1,500 bytes is 12,000 bits.
Programmers convert to see how many bits a type or a field holds, which sets the largest number it can store: 4 bytes is 32 bits, enough for about 4.29 billion values. Network engineers convert packet sizes to bits to work out how long they take on a link measured in bits per second.
Examples
- 1 B (one byte, a single ASCII character) is 8 bit
- 4 B (a 32-bit integer or an IPv4 address) is 32 bit
- 16 B (an IPv6 address) is 128 bit
- 1,500 B (the standard Ethernet MTU) is 12,000 bit
Bytes to bits chart
| Bytes (B) | Bits |
|---|---|
| 1 | 8 |
| 2 | 16 |
| 3 | 24 |
| 4 | 32 |
| 6 | 48 |
| 8 | 64 |
| 10 | 80 |
| 12 | 96 |
| 16 | 128 |
| 20 | 160 |
| 24 | 192 |
| Bytes (B) | Bits |
|---|---|
| 32 | 256 |
| 48 | 384 |
| 64 | 512 |
| 100 | 800 |
| 128 | 1,024 |
| 256 | 2,048 |
| 512 | 4,096 |
| 1,000 | 8,000 |
| 1,024 | 8,192 |
| 1,500 | 12,000 |