/30 subnet (255.255.255.252)
Everything about a /30 network: mask, wildcard, number of hosts, example ranges and when to use it.
| Prefix (CIDR) | /30 |
|---|---|
| Subnet mask | 255.255.255.252 |
| Wildcard mask | 0.0.0.3 |
| Total addresses | 4 |
| Usable hosts | 2 |
| Block size | 4 in the fourth octet |
| Mask in binary | 11111111.11111111.11111111.11111100 |
What is a /30 used for?
Point-to-point links between two routers: exactly 2 usable addresses, one for each end. 64 subnets of /30 fit in one /24.
How the numbers are worked out
/30 means the first 30 bits of the address are the network part, leaving 2 bits for hosts. 22 = 4 addresses. Take away 2 for the network and broadcast addresses and you get 2 usable hosts.
The mask has 30 ones followed by 2 zeros. The wildcard mask is the opposite: 255.255.255.255 minus the subnet mask, 0.0.0.3.
Example /30 networks
| Network | Usable range | Broadcast |
|---|---|---|
192.168.1.0/30 | 192.168.1.1 – 192.168.1.2 | 192.168.1.3 |
192.168.1.4/30 | 192.168.1.5 – 192.168.1.6 | 192.168.1.7 |
192.168.1.8/30 | 192.168.1.9 – 192.168.1.10 | 192.168.1.11 |
192.168.1.12/30 | 192.168.1.13 – 192.168.1.14 | 192.168.1.15 |
Each next /30 network starts 4 addresses after the previous one. Work out any address with the free subnet calculator, or split a network into different sizes with the VLSM planner.
Frequently asked questions
How many hosts are in a /30 subnet?
A /30 has 4 addresses in total and 2 usable hosts. The first address is the network address and the last is the broadcast address.
What is the subnet mask for /30?
The subnet mask for /30 is 255.255.255.252, and the wildcard mask (used in Cisco ACLs and OSPF) is 0.0.0.3.
What is a /30 subnet used for?
Point-to-point links between two routers: exactly 2 usable addresses, one for each end.
Other prefix sizes
Learn more: subnetting in your head, subnetting step by step and the subnetting cheat sheet.