Wildcard Mask Calculator

Convert subnet masks to wildcard masks and inverse masks for ACLs, OSPF, and Cisco access list configuration.

Built by a network engineerCalculations run locally in your browserNo signup requiredNetwork information is not transmitted to our servers

Wildcard Mask Calculator

Results

Subnet Mask
255.255.255.0
Wildcard Mask
0.0.0.255
CIDR Prefix
/24
Binary Subnet Mask
11111111.11111111.11111111.00000000
Binary Wildcard Mask
00000000.00000000.00000000.11111111

What the Wildcard Mask Calculator Does

The wildcard mask calculator converts between CIDR prefixes, subnet masks, and wildcard (inverse) masks. It displays both dotted-decimal and binary representations, making it easy to verify values for ACL rules, OSPF network statements, and other Cisco configurations that require wildcard masks.

How the Calculation Works

A wildcard mask is the bitwise NOT of the subnet mask — every 1 becomes 0 and every 0 becomes 1. For a /24 subnet mask of 255.255.255.0 (binary 11111111.11111111.11111111.00000000), the wildcard mask is 0.0.0.255 (binary 00000000.00000000.00000000.11111111). In ACL entries, a 0 bit in the wildcard mask means the corresponding IP bit must match exactly, while a 1 bit means it can be any value.

Example

For a /24 network:

  • Subnet mask: 255.255.255.0
  • Wildcard mask: 0.0.0.255
  • CIDR: /24

In a Cisco ACL, to match the entire 192.168.1.0/24 network:

access-list 10 permit 192.168.1.0 0.0.0.255

Common Use Cases

  • Generating wildcard masks for Cisco ACL permit/deny rules
  • Configuring OSPF network statements with correct wildcard masks
  • Converting between subnet mask and CIDR notation
  • Verifying binary representations for educational purposes

Important Considerations

Wildcard masks are sometimes confused with subnet masks, but they serve different purposes. A subnet mask defines the network boundary, while a wildcard mask defines which bits of an IP address to match in an ACL or routing protocol statement. The two are inverses of each other. Always double-check that you are using the correct mask type for the context — using a subnet mask where a wildcard mask is required (or vice versa) is a common configuration error.

Related tools

Frequently Asked Questions

What is a wildcard mask?

A wildcard mask is the bitwise inverse of a subnet mask. In Cisco ACLs and OSPF configuration, 0 bits mean the corresponding IP bit must match, and 1 bits mean it can be any value.

How do I convert a subnet mask to a wildcard mask?

Subtract each octet of the subnet mask from 255. For example, 255.255.255.0 becomes 0.0.0.255 (255-255=0, 255-255=0, 255-255=0, 255-0=255).

Are wildcard masks and subnet masks the same?

No. They are inverses of each other. A subnet mask of 255.255.255.0 corresponds to a wildcard mask of 0.0.0.255. Using the wrong type is a common configuration error.

Technically Reviewed By

Senior Enterprise Network Engineer — 25+ years of IT and network infrastructure experience, including enterprise Cisco switching, routing, wireless, firewalls, VPN, network access control, SD-WAN, and large-scale network operations.

Last reviewed: 2026-09-04

Calculations are performed using standards-based formulas and verified against known reference values. All computation runs client-side in your browser.

Related Resources