Last reviewed: May 2026
A /31 subnet contains exactly 2 IP addresses. Unlike any other subnet size, the /31 is governed by a special rule: RFC 3021 defines that both addresses in a /31 can be used as host addresses on point-to-point links, with no network address or broadcast address reserved. This makes /31 the most IP-efficient way to number a router-to-router connection.
Calculate any /31 subnet instantly →Published in December 2000, RFC 3021 defines that when a subnet mask of /31 is applied to a point-to-point link, the two addresses in the block are treated as host addresses — the concept of network address and broadcast address does not apply. This is supported by all modern routing platforms: Cisco IOS 12.2+, Juniper Junos, Arista EOS, Nokia SR OS, and others.
| Property | Value |
|---|---|
| Prefix length | /31 |
| Subnet mask | 255.255.255.254 |
| Wildcard mask | 0.0.0.1 |
| Total addresses | 2 |
| Usable hosts (RFC 3021) | 2 — both addresses assignable on point-to-point links |
| Usable hosts (traditional) | 0 — traditional math: 21 − 2 = 0 |
| Network address | Not applicable (per RFC 3021) |
| Broadcast address | Not applicable (per RFC 3021) |
| Binary mask | 11111111.11111111.11111111.11111110 |
| AWS VPC support | Not supported — minimum is /28 |
A /30 has 4 addresses: 1 network + 2 hosts + 1 broadcast. Using /30 for every WAN link wastes 2 out of every 4 addresses. A /31 uses just 2 addresses for the same 2 hosts — 50% more efficient. For an ISP with thousands of point-to-point links, this saves a significant portion of the IPv4 address pool.
| Property | /31 (RFC 3021) | /30 (traditional P2P) |
|---|---|---|
| Total addresses | 2 | 4 |
| Usable hosts | 2 | 2 |
| Wasted addresses | 0 | 2 (network + broadcast) |
| AWS VPC support | No | No (below /28 minimum) |
| Modern router support | Yes (IOS 12.2+, Junos, Arista) | Yes (universal) |
| BGP session support | Yes — preferred by many ISPs | Yes |
| Device | IP Address | Role |
|---|---|---|
| Router A (your ASN) | 203.0.113.0/31 | eBGP peer, interface address |
| Router B (peer ASN) | 203.0.113.1/31 | eBGP peer, interface address |
| CIDR | Subnet Mask | Total IPs | Usable Hosts | AWS Usable | Typical Use |
|---|---|---|---|---|---|
| /28 | 255.255.255.240 | 16 | 14 | 11 | AWS minimum; small managed subnet |
| /29 | 255.255.255.248 | 8 | 6 | 3 | Small server cluster; mgmt VLAN |
| /30 | 255.255.255.252 | 4 | 2 | — | Traditional point-to-point link |
| /31 | 255.255.255.254 | 2 | 2 (RFC 3021) | — | Efficient P2P link — ISP/backbone |
| /32 | 255.255.255.255 | 1 | 1 host route | — | Loopback, host route, anycast |