How to calculate wildcard mask? [Easy Way]

July 28, 2011

Some students of Computer Networking especially those appearing in Certification exams such as Cisco Certification Exams or Juniper Certification Exams have problem in calculating wildcard mask. Some know the concept but their method is difficult that might result in wastage of time which may prove to be a problem in certification exams. Also, the wildcard mask is used in extensively in Access Control Lists (ACLs), EIGRP and OSPF, so learning how to calculate wildcard mask is important. We have decided to share a very simple method to calculate the wildcard mask efficiently and hopefully you will not have any ‘how to calculate wildcard mask?’ afterwards.

The method is: first calculate the subnet mask for the network for which you want to find the wildcard mask. Then subtract that subnet mask from

An example will explain this method more efficiently.  Consider you have a network of and you want to calculate the wildcard mask for it.  We know that the subnet mask for this network is Now we subtract this subnet mask from as follow:



As you can see, is our required wildcard mask. Using this method we can find any wildcard mask easily.

Take another example, if you have network address of We know that the subnet mask for this network address is

Using the above mentioned method, wildcard mask is:



Wildcard mask, found nice and easy.

 If you any comments or questions, put them in comments section and we would be happy to answer them.



  • Pojaaa

    very easy method…thanks..

    • Rajiv Indore

       how to find wildcard mask of ? – = (this ans is wrong and show value is /32 in next router) how to show /16 in next router
      plz  rpy on

      • NerdCrunch is the correct mask for /16.

        • Bilal Baig

          NerdCrunch ? Then what will be the range of this wildcard mask for the concerning IPs ? Please explain…
          Wild card mask:
          given ip : /16
          Range: -to- ?.?.?.?

          • Randy Forsland


  • NerdCrunch


    • Admin

      Good to hear that it helped.

  • K.Chenchukumar

    Simple Way to Understanding  WCM

  • Rg1145

     how to find wildcard mask of ?
    plz rpy

    • NerdCrunch

  • jay

    what is wild card mask for …pls rply

    • NerdCrunch

      Wild Card Mask will be

    • milky

  • sam

    thank you very much…………….

  • milky

    what is wild card mask for the range of to and tell me how???????? thanks rely soon

    • Eddie Salgado

      Answer : description is to 23 uses the Network with the /28 CIDR notation or (subnet mask) of – Formula is – =

      • Bilal Baig

        Eddie Salgado? Can you please tell me, what if I say wildcard mask for the to is
        I will wait for your kind reply…

        • Randy Forsland

          Bilal is correct. to 23 is /29,,not / inverse mask is

          • mike sharma

            This is Incorrect.This is network ID. to 23 uses wildcard mask.Eddie Salgado is right

  • srivatsa

    the wild card mask for is … How?? could u pls explain it ???

    • Bilal Baig

      srivatsa ? Where did you read or find that is wildcard mask for the IP ?
      Can you please share that page with me…? Please don’t mind !

  • Bilal Baig

    Last IP address – First IP address = Wildcard mask
    e.g; – = – = – =

    In the same way we can calculate wildcard mask for the sub-networks easily. Let say,
    you want to calculate wildcard for the IPs in the range : to

    then your first ip is :
    and your last ip is:

  • Bilal Baig

    Can any body help me to find out the Difference b/w the Wildcard masks using for the OSPF and ACLs ?

    I have noticed that in ACL we can give all kinds of wildcard mask.
    But, in OSPF we cannot give all kinds of wildcard masks …. Why?

    If someone know, then please share your experience with us…Thank you !

    If you also want to notice it, then try to use the as wildcard mask in OSPF configuration and also ACL configuration. And after that must share your experience, please !

    HINT: Dis-contiguous mask error while ospf configuration but not for the acl configuration

  • K Ing Rawezh

    what is wildcard for

  • erostand premier

    Please which wildcard mask is the most efficient to use when specifying this networks in a single ACL entry?

    • NerdCrunch

      • erostand premier

        Thanks for your reply, meaning the wildcard mask is
        0 . 0 . 3 . 255

        please for an explaination