/7 Subnet Mask ReferenceIPv4
Two /8s side by side compose a /7: mask <code>254.0.0.0</code>, 33,554,432 addresses. It is the widest prefix you will regularly see attached to realistic-looking public ranges in worked examples.
/7 facts at a glance
- Subnet mask
- 254.0.0.0
- Wildcard mask
- 1.255.255.255
- Binary mask
- 11111110.00000000.00000000.00000000
- Total addresses
- 33,554,432
- Usable hosts
- 33,554,430 (excludes network & broadcast)
- Block size
- 33,554,432 addresses (225)
- Typical role
- Aggregation and supernetting
Example /7 networks
A /7 spans a large share of the address space, so one aligned example says it all.
| Network | Usable range | Usable hosts |
|---|---|---|
| 198.0.0.0/7 | 198.0.0.1 – 199.255.255.254 | 33,554,430 |
How to calculate a /7 mask
A /7 mask sets the first 7 bits of a 32-bit number to 1 and leaves the remaining 25 bits as 0. In binary that reads 11111110.00000000.00000000.00000000, which converts to dotted decimal 254.0.0.0. Each block covers a contiguous run of 225 = 33,554,432 addresses, and every block starts at a multiple of that size. The wildcard simply flips every bit, giving 1.255.255.255.
Where /7 is used
- Pairing exercises, such as <code>68.0.0.0/7</code> summarizing 68.0.0.0 through 69.255.255.255.
- Theory problems about summarizing adjacent classful-era blocks.
- Sanity checks that a candidate summary aligns on its bit boundary.
A /7 always begins on an even first octet. <code>205.0.0.0/7</code> is impossible; <code>204.0.0.0/7</code> is properly aligned and covers 204.0.0.0 through 205.255.255.255.
Frequently asked questions
What mask does /7 use?
<code>254.0.0.0</code>, wildcard <code>1.255.255.255</code>: seven one-bits and twenty-five host bits.
How many addresses are in a /7?
33,554,432 total and 33,554,430 usable by convention, which amounts to two complete /8s per block.
Can a /7 start on an odd first octet?
No. The seventh bit is the last fixed bit, so valid networks pair an even first octet with the odd one after it, like 206 together with 207.
Open this block in a calculator
Open the /7 block in the subnet calculator