best, or possibly worst, explanation of subnet masks ever

Trying to explain subnet masks inside our company chat system, and this was the result. It is either the best, or possibly the worst, explanation of subnet masks and IP addresses ever. So there is that.

Credits: Images from this on IPV4 CIDR

My #knowledgeshare began like this and went down from there. But the actual IP is definitely about to be blocked. Hence I changed the IP to something ridiculous to protect the GUILTY:

after hours #knowledgeshare

the IP is but I *only* want to block that one IP so I used a ‘subnet mask’ of 32 which looks like this  (not the real IP but you get the idea)

Because on the surface /32 makes NO SENSE AT ALL! Why? Because masks are binary. Obviously, right?

If you look at it in binary a pattern emerges like this big chart which also looks a bit scary.

ipv4 subnet mask in binary
IP V4 Table from

Think of the zero’s as “hey you are cool man. come on into the party dude!” and the ones are like “oh hell no you aren’t getting in here!”

So the 1’s are the “mask” in a subnet mask.

Visualized another way it looks like the following party-pic. These guys are PARTYING HARD with 256 IPs.

IP binary subnet mask

But  you know, first you can’t have a zero IP address so you can’t use Then you’ve got the supervisor (router) who gets the first IP in the block (e.g. is the router in

Then you have the drunk screamer – that is the broadcaster. Think Robin Williams in Good Morning Vietnam! This guy, the biggest in the subnet, gets the last number.

In our example subnet that is (remember IPs start at 0. Thus 0 to 255 = 256 IPs.) Anyway this guy –> “” is the guy who is like HEY WHO THE HELL IS IN HERE!!!?!?!?!  And now everyone has to reply because they are screaming and we all have to answer!

So that leaves 254 (1router-broadcast=254) available host ips in this block. Further by convention you typically don’t assign the .0 IP so that really leaves 253. Basically it looks like this in



Octet 2⁸ /24 256