IPv4 Subnetting: A Quick Overview

The practice of dividing a network into two or more networks is called subnetting. We steal bits from the hosts to create more subnets.

Public IP range – Used with the public network ex. WAN; Recognized over the internet, assigned by IANA or service provider. globally unique, cost associated with public IP.

 

CLASS

IP Address Range

Network Mask

Prefix

Number of Networks

Number of hosts

A

1 to 126 – Used for huge networks, like those deployed by Internet Service Providers (ISPs).

255.0.0.0

/8

125

16,777,241

B

128 to 191 – Used for medium and large-sized networks in enterprises and organizations

255.255.0.0

/16

16,382

65,534

C

192 to 223 – Used for small-sized networks.

255.255.255.0

/24

2,097,150

254

D

224 to 239 – Used for multicasting applications

Multicast Addresses

E

240 to 254 – Reserved for experimental purposes only for R&D or Study.

R&D, Restricted/Experimental

 

The above table is standard and good to remember but the actual range will look like below after excluding private IP range.

 

CLASS A

1.0.0.0 – 9.255.255.255

11.0.0.0 – 126.255.255.255

CLASS B

128.0.0.0 – 172.15.255.255

172.32.0.0 – 191.255.255.255

CLASS C

192.0.0.0 – 192.167.255.255

192.169.0.0 – 223.255.255.255

 

127.0.0.0 is reserved for loopback (localhost).

 

Private IP range – Used with the private network ex. LAN; Not recognized over the internet, assigned by LAN Admin. unique only in LAN segment. free of charge.

 

CLASS A

10.0.0.0 – 10.255.255.255 – Used for private network, local LAN.

CLASS B

172.16.0.0 – 172.31.255.255 – Used for private network, local LAN.

CLASS C

192.168.0.0 – 192.168.255.255 – Used for private network, local LAN.

 

Types of Subnetting

  • Fixed Length Subnetting – All the subnets are of same size, same subnet mask, equal number of hosts. It is also called as classful subnetting.
  • Variable Length Subnetting – All the subnets are not of same size, do not have same subnet mask, no equal number of hosts. It is also called as classless subnetting

 

Types of addresses

  • Network address – Network address represents the network.
  • Broadcast address – Broadcast address represents all the hosts which belong to it.

 

Subnetting Table (Class A) –

 

NetBits

Network Mask

Subnets

Number of Hosts

/8

255.0.0.0

0

16,777,214

/9

255.128.0.0

0

8,388,606

/10

255.192.0.0

2

4,194,302

/11

255.224.0.0

6

2,097,150

/12

255.240.0.0

14

1,048,574

/13

255.248.0.0

30

524,286

/14

255.252.0.0

62

262,142

/15

255.254.0.0

126

131,070

/16

255.255.0.0

254

65,534

/17

255.255.128.0

510

32,766

/18

255.255.192.0

1,022

16,382

/19

255.255.224.0

2,046

8,190

/20

255.255.240.0

4,094

4,094

/21

255.255.248.0

8,190

2,046

/22

255.255.252.0

16,382

1,022

/23

255.255.254.0

32,766

510

/24

255.255.255.0

65,534

254

/25

255.255.255.128

131,070

126

/26

255.255.255.192

262,142

62

/27

255.255.255.224

524,286

30

/28

255.255.255.240

1,048,574

14

/29

255.255.255.248

2,097,150

6

/30

255.255.255.252

4,194,302

2

 

Subnetting Table (Class B) –

 

NetBits

Network Mask

Subnets

Number of Hosts

/16

255.255.0.0

0

65,534

/17

255.255.128.0

0

32,766

/18

255.255.192.0

2

16,382

/19

255.255.224.0

6

8,190

/20

255.255.240.0

14

4,094

/21

255.255.248.0

30

2,046

/22

255.255.252.0

62

1,022

/23

255.255.254.0

126

510

/24

255.255.255.0

254

254

/25

255.255.255.128

510

126

/26

255.255.255.192

1,022

62

/27

255.255.255.224

2,046

30

/28

255.255.255.240

4,094

14

/29

255.255.255.248

8,190

6

/30

255.255.255.252

16,382

2

 

Subnetting Table (Class C) –

 

NetBits

Network Mask

Subnets

Number of Hosts

/24

255.255.255.0

0

254

/25

255.255.255.128

0

126

/26

255.255.255.192

2

62

/27

255.255.255.224

6

30

/28

255.255.255.240

14

14

/29

255.255.255.248

30

6

/30

255.255.255.252

62

2