Subnet Mask to Wildcard Converter
Calculate the inverse IPv4 mask.
Subnet Mask to Wildcard Converter: inputs and results
Enter an IP address, CIDR prefix, or range. Then check its first and last address below.
Calculated Boundaries & ParametersReady
Key Capabilities
- •100% Client-Side: Zero telemetry or server latency.
- •RFC Compliant: Exact 32-bit and 128-bit integer precision.
- •Quick Copy: Instant access to CIDR, mask, and range bounds.
- •Cross-Platform: Works on desktop, tablet, and mobile browsers.
Related Masks, Wildcards & ACLAll Tools
IP Address and Mask Calculator
Calculate the corresponding network range.
CIDR to Subnet Mask Converter
Convert IPv4 prefixes to dotted masks.
Subnet Mask to CIDR Converter
Find prefix length from contiguous masks.
Subnet Mask Validator
Check mask structure and contiguity.
Wildcard Mask to Subnet Mask Converter
Convert compatible contiguous wildcard masks.
ACL Wildcard Match Calculator
Evaluate address-and-wildcard matching.
How Subnet Mask to Wildcard Converter Works?
This tool works by subtracting each mask octet from 255, which flips every bit of the mask.
Enter a mask or prefix
Type
255.255.240.0or/20.Validate the mask
The converter confirms that the mask is contiguous.
Subtract each octet from 255
255 − 255 = 0, 255 − 255 = 0, 255 − 240 = 15, 255 − 0 = 255.
Return the wildcard
The result is
0.0.15.255, ready for ACL and OSPF statements.
Subnet Mask to Wildcard Converter Formula
The formula is Wildcard = 255.255.255.255 − Subnet Mask, applied octet by octet.
Per-octet rule
W_i = 255 − M_iFor each of the 4 octets.
Bitwise rule
W = NOT MFlips all 32 bits.
From prefix
W = 2^(32−p) − 1For /20: 4,095 = 0.0.15.255.
Worked example: 255.255.240.0
255 − 255 = 0 255 − 255 = 0 255 − 240 = 15 255 − 0 = 255 Wildcard = 0.0.15.255
Subnet Mask to Wildcard Converter Conversion Table
The table lists the wildcard mask for 17 subnet masks, /16 through /32, with the binary form of each wildcard.
| Subnet Mask | CIDR | Wildcard Mask | Wildcard Binary |
|---|---|---|---|
| 255.255.0.0 | /16 | 0.0.255.255 | 00000000.00000000.11111111.11111111 |
| 255.255.128.0 | /17 | 0.0.127.255 | 00000000.00000000.01111111.11111111 |
| 255.255.192.0 | /18 | 0.0.63.255 | 00000000.00000000.00111111.11111111 |
| 255.255.224.0 | /19 | 0.0.31.255 | 00000000.00000000.00011111.11111111 |
| 255.255.240.0 | /20 | 0.0.15.255 | 00000000.00000000.00001111.11111111 |
| 255.255.248.0 | /21 | 0.0.7.255 | 00000000.00000000.00000111.11111111 |
| 255.255.252.0 | /22 | 0.0.3.255 | 00000000.00000000.00000011.11111111 |
| 255.255.254.0 | /23 | 0.0.1.255 | 00000000.00000000.00000001.11111111 |
| 255.255.255.0 | /24 | 0.0.0.255 | 00000000.00000000.00000000.11111111 |
| 255.255.255.128 | /25 | 0.0.0.127 | 00000000.00000000.00000000.01111111 |
| 255.255.255.192 | /26 | 0.0.0.63 | 00000000.00000000.00000000.00111111 |
| 255.255.255.224 | /27 | 0.0.0.31 | 00000000.00000000.00000000.00011111 |
| 255.255.255.240 | /28 | 0.0.0.15 | 00000000.00000000.00000000.00001111 |
| 255.255.255.248 | /29 | 0.0.0.7 | 00000000.00000000.00000000.00000111 |
| 255.255.255.252 | /30 | 0.0.0.3 | 00000000.00000000.00000000.00000011 |
| 255.255.255.254 | /31 | 0.0.0.1 | 00000000.00000000.00000000.00000001 |
| 255.255.255.255 | /32 | 0.0.0.0 | 00000000.00000000.00000000.00000000 |
What is Subnet Mask to Wildcard Converter?
The Subnet Mask to Wildcard Converter is a tool that calculates the wildcard mask, the bitwise inverse of a subnet mask. 255.255.255.0 becomes 0.0.0.255.
Cisco IOS ACLs, OSPF network statements, and EIGRP configurations use wildcard masks. A 0 bit in a wildcard means "must match" and a 1 bit means "ignore". The inverse of a subnet mask produces a wildcard that matches exactly that subnet.
Mixing up the 2 formats is a common configuration error. A subnet mask entered where a wildcard is expected matches the wrong addresses without any error message.
What are the uses of Subnet Mask to Wildcard Converter?
There are 4 main uses of the Subnet Mask to Wildcard Converter, including ACL entries, OSPF statements, and EIGRP configuration.
Writing Cisco ACL entries
access-list 10 permit 10.1.16.0 0.0.15.255matches the /20 subnet.Configuring OSPF areas
network 10.1.16.0 0.0.15.255 area 0enables OSPF on matching interfaces.Configuring EIGRP networks
EIGRP
networkcommands accept a wildcard to select interfaces.Checking existing configurations
Reviewers convert wildcards back to masks to confirm the intended subnet.