Definition

IP addressing refers to the process of assigning a unique numerical label, called an IP address, to each device connected to a computer network that uses the Internet Protocol (IP) for communication. IP addresses are used to identify and locate devices on the network and route data between them.

There are two types of IP addresses: IPv4 (32-bit) and IPv6 (128-bit). IPv4 is the most widely used, but IPv6 is gradually replacing it due to the increasing number of internet-connected devices.

Syntax of IP address

Each IP address consists of two parts: a network portion and a host portion. The network portion of the IP address identifies the network the device is connected to, while the host portion identifies the specific device within that network. IP addresses can be either static (manually assigned) or dynamic (automatically assigned by a DHCP server).

Types of IP Addressing

There are two versions of IP addresses in use today: IPv4 and IPv6.

IPv4 addressing

IPv4 addresses are 32-bit numbers with each octet (group of 8 bits) separated by a period represented in dotted decimal notation (e.g. 192.168.0.1).

IPv4 addresses are divided into five classes (A, B, C, D, and E), each of which has a specific range of values and a different number of network and host bits.

The IPv4 class system has been largely replaced by Classless Inter-Domain Routing (CIDR) notation, which allows for more flexible assignment of IP addresses.

| IPv4 address | Higher order bits ($1^{st}$ octet bits) | Net ID Bits | Host ID Bits | Number of networks | Address per network | Network (N) & Host parts (H) | Start Address | End Address | Subnet | Number of possible networks and hosts per network | Use-case | | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | | Class A | 00000000 - 01111111 | 8 | 24 | $2^7$ (128) | $2^{24}$ (16777216) | N.H.H.H | 0.0.0.0 | 127.255.255.255 | 255.0.0.0 | 128 nets ($2^7$) $2^{24}-2$ = 16777214 hosts | Large networks | | Class B | 10000000 - 10111111 | 16 | 16 | $2^{14}$ (16384) | $2^{16}$ (65536) | N.N.H.H | 128.0.0.0 | 191.255.255.255 | 255.255.0.0 | 16384 nets ($2^{14}$) $2^{16}-2$ = 65534 hosts | Medium size networks | | Class C | 11000000 - 11011111 | 24 | 8 | $2^{21}$ (2097152) | $2^8$ (256) | N.N.N.H | 192.0.0.0 | 223.255.255.255 | 255.255.255.0 | 2097152 nets ($2^{21}$) $2^8-2$ = 254 hosts | Small networks | | Class D | 11100000 - 11101111 | NA | NA | NA | NA | NA | 224.0.0.0 | 239.255.255.255 | NA | NA | Multicast addresses | | Class E | 11110000 - 11111111 | NA | NA | NA | NA | NA | 240.0.0.0 | 255.255.255.255 | NA | NA | Experimental use |

Class A address: