UrbanPro
true
default_background

Learn Computer Networking from the Best Tutors

  • Affordable fees
  • 1-1 or Group class
  • Flexible Timings
  • Verified Tutors
✕

Search in

Introduction to IPv4 Addressing – Learn Networking Basics

Profile Photo Adithya Vara Kumar D
15 hrs ago 0 View Comments0

IPv4 Addressing – Complete Beginner-Friendly Lesson

  1. What is an IP Address?

An IP (Internet Protocol) address is a unique logical address assigned to a device connected to a network.

It helps devices identify each other and communicate over a network.

Example:

192.168.1.10

Just like your home has a postal address, your computer needs an IP address to communicate with other devices.

  1. What is IPv4?

IPv4 stands for Internet Protocol Version 4.

  • IPv4 uses a 32-bit address.
  • It is divided into 4 parts called octets.
  • Each octet contains 8 bits.
  • Each octet is separated by a dot (.).
  • Each octet can have a value from 0 to 255.

Example:

192.168.1.10

192

8 bits

1st Octet

168

8 bits

2nd Octet

1

8 bits

3rd Octet

10

8 bits

4th Octet

8 + 8 + 8 + 8 = 32 bits

Why does an octet have values from 0 to 255?

Each bit can have either 0 or 1.

8 bits can represent 256 different combinations (2⁸ = 256).

Therefore, the range is 0 to 255.

  1. Binary Representation of IPv4

Computers understand binary numbers (0s and 1s).

For example:

IP Address: 192.168.1.10

Decimal

Binary

192

11000000

168

10101000

1

00000001

10

00001010

So, the complete IPv4 address is represented using 32 binary bits.

  1. IPv4 Address Classes

IPv4 addresses were traditionally divided into five classes: A, B, C, D and E.

Class

First Octet Range

Default Subnet Mask

Purpose

A

1–126

255.0.0.0 (/8)

Large networks

B

128–191

255.255.0.0 (/16)

Medium networks

C

192–223

255.255.255.0 (/24)

Small networks

D

224–239

Not applicable

Multicasting

E

240–255

Not applicable

Experimental / Reserved

Important points:

  • Class A: First octet represents the network portion.
  • Class B: First two octets represent the network portion.
  • Class C: First three octets represent the network portion.
  • Class D: Used for multicast communication.
  • Class E: Reserved for experimental purposes.

Example of identifying the class

  • 10.1.1.1 → Class A
  • 172.16.1.1 → Class B
  • 192.168.1.1 → Class C
  • 230.1.1.1 → Class D
  • 245.1.1.1 → Class E

Note: 127.x.x.x is reserved for loopback testing, so it is excluded from normal Class A host addressing.

  1. What is a Subnet Mask?

A subnet mask helps us identify which portion of an IP address belongs to the network and which portion belongs to the host (device).

In simple words:

  • Network portion identifies the network.
  • Host portion identifies the individual device within that network.

Example:

  • IP Address: 192.168.1.10
  • Subnet Mask: 255.255.255.0

Here:

  • Network Address: 192.168.1.0
  • Host portion: 10

The device belongs to the 192.168.1.0 network.

  1. Default Subnet Masks

Every traditional IPv4 address class has a default subnet mask.

Class

Default Subnet Mask

CIDR

A

255.0.0.0

/8

B

255.255.0.0

/16

C

255.255.255.0

/24

What is CIDR notation?

CIDR stands for Classless Inter-Domain Routing.

Instead of writing the complete subnet mask, we can use a slash followed by a number.

Examples:

  • 255.0.0.0 = /8
  • 255.255.0.0 = /16
  • 255.255.255.0 = /24

The number represents how many bits are used for the network portion.

  1. Public IP Address vs Private IP Address

IPv4 addresses are also classified as public and private addresses.

Private IP Address

A private IP address is used inside a local network, such as a home, school or office network.

Examples:

  • 192.168.1.10
  • 10.0.0.5
  • 172.16.1.20

Private IP addresses cannot be directly routed over the public internet.

Public IP Address

A public IP address is used to identify a network or device on the internet. It is globally unique at a given time.

Example: 8.8.8.8 (Google Public DNS).

Private IPv4 Address Ranges

Range

Private IP Block

Class A range

10.0.0.0 – 10.255.255.255

Class B range

172.16.0.0 – 172.31.255.255

Class C range

192.168.0.0 – 192.168.255.255

These are the three officially reserved private IPv4 blocks.

Real-world example:

Imagine you have Wi-Fi at home.

  • Your laptop: 192.168.1.10
  • Your mobile: 192.168.1.11
  • Your smart TV: 192.168.1.12

All these devices use private IP addresses. Your router generally uses a public IP address to communicate with the internet.

  1. What is NAT?

NAT stands for Network Address Translation.

It allows devices using private IP addresses to communicate with the internet by translating their private addresses into a public address.

Example:

Your laptop, mobile and TV share the router's public IP address when accessing the internet (typically using PAT, also called NAT overload).

  1. Static IP vs Dynamic IP

Static IP Address

An IP address that is manually configured or reserved to remain the same.

Example: A company server may use a static IP address.

Dynamic IP Address

An IP address automatically assigned to a device, usually through DHCP.

Example: When your mobile connects to Wi-Fi, the router can automatically assign it an IP address.

Static IP

Dynamic IP

Remains fixed unless changed

Can change over time

Manually configured or reserved

Automatically assigned

Useful for servers

Common for user devices

  1. Important Special IPv4 Addresses

IP Address / Range

Purpose

127.0.0.1

Loopback address

0.0.0.0

Unspecified address

255.255.255.255

Limited broadcast address

169.254.0.0/16

Link-local addressing (APIPA)

224.0.0.0/4

Multicast address range

Remember:

  • 127.0.0.1 means your own computer.
  • 169.254.x.x is commonly assigned when DHCP fails and no address is obtained.
  • 255.255.255.255 is used for a local broadcast.
  1. What is DHCP?

DHCP stands for Dynamic Host Configuration Protocol.

It automatically provides IP configuration to devices, including:

  1. IP Address
  2. Subnet Mask
  3. Default Gateway
  4. DNS Server

Example:

When you connect your laptop to Wi-Fi, DHCP can automatically assign:

  • IP Address: 192.168.1.10
  • Subnet Mask: 255.255.255.0
  • Default Gateway: 192.168.1.1
  • DNS Server: 8.8.8.8

You don't need to enter these details manually.

  1. Quick Revision – Important Points

Topic

Remember

IPv4

32 bits

Octets

4

Bits per octet

8

Decimal range

0–255

Class A mask

/8

Class B mask

/16

Class C mask

/24

Private IP

Used in local networks

Public IP

Used on the internet

NAT

Translates private and public addresses

DHCP

Automatically assigns IP configuration

Loopback

127.0.0.1

  1. Practice Questions
  1. How many bits are there in an IPv4 address?
  2. How many octets are present in IPv4?
  3. What is the range of each octet?
  4. What is the default subnet mask of Class A?
  5. Which class is used for multicast?
  6. Is 192.168.1.10 a public or private IP?
  7. What is the purpose of NAT?
  8. What is the use of DHCP?
  9. What does 127.0.0.1 represent?
  10. What is the CIDR notation of 255.255.255.0?

 

0 Dislike
Follow 1 Loading Spinner
Default Profile Photo

Please Enter a comment

Submit

Other Lessons for You


A note on working of Transmission Control Protocol in Computer Networks.
TCP Connection establishment and termination TCP is one of theTCP is connection oriented protocol and reliable protocol. It originated in the initial network implementation in which it complemented the...
Profile Photo

Networking for All - Beginning with Basics
Introduction What is Network?A network is a group of two or more computer systems linked together. In general Networking means connectivity. Why Networking?Computers are interconnected for serving...
Profile Photo

Anything could be understood, if learned in proper way, and by good coach.
Anything could be understood, if learned in proper way, and by good coach. Every body has there own way and pace of grasping things, so mentor/coach should be in sync (neither too fast nor too slow) with...
Profile Photo

Ethical hacking : Important points for beginners
Dear passionate learners, I am posting below lesson to create enthusiasm among you all for learning ethical hacking . A beginner in Ethical Hacking is always in dilemma. Below are some misconceptions,...
Profile Photo
X

Looking for Computer Networking Classes?

The best tutors for Computer Networking Classes are on UrbanPro

  • Select the best Tutor
  • Book & Attend a Free Demo
  • Pay and start Learning

Learn Computer Networking with the Best Tutors

The best Tutors for Computer Networking Classes are on UrbanPro

This website uses cookies

We use cookies to improve user experience. Choose what cookies you allow us to use. You can read more about our Cookie Policy in our Privacy Policy

Accept All
Decline All

UrbanPro.com is India's largest network of most trusted tutors and institutes. Over 55 lakh students rely on UrbanPro.com, to fulfill their learning requirements across 1,000+ categories. Using UrbanPro.com, parents, and students can compare multiple Tutors and Institutes and choose the one that best suits their requirements. More than 7.5 lakh verified Tutors and Institutes are helping millions of students every day and growing their tutoring business on UrbanPro.com. Whether you are looking for a tutor to learn mathematics, a German language trainer to brush up your German language skills or an institute to upgrade your IT skills, we have got the best selection of Tutors and Training Institutes for you. Read more