For working professionals
For fresh graduates
More
Talk to our experts. We are available 7 days a week, 9 AM to 12 AM (midnight)
Indian Nationals
Foreign Nationals
The above statistics depend on various factors and individual results may vary. Past performance is no guarantee of future results.
The student assumes full responsibility for all expenses associated with visas, travel, & related costs. upGrad does not .
1. Introduction
6. PyTorch
9. AI Tutorial
10. Airflow Tutorial
11. Android Studio
12. Android Tutorial
13. Animation CSS
16. Apex Tutorial
17. App Tutorial
18. Appium Tutorial
21. Armstrong Number
22. ASP Full Form
23. AutoCAD Tutorial
27. Belady's Anomaly
30. Bipartite Graph
35. Button CSS
39. Cobol Tutorial
46. CSS Border
47. CSS Colors
48. CSS Flexbox
49. CSS Float
51. CSS Full Form
52. CSS Gradient
53. CSS Margin
54. CSS nth Child
55. CSS Syntax
56. CSS Tables
57. CSS Tricks
58. CSS Variables
61. Dart Tutorial
63. DCL
65. DES Algorithm
83. Dot Net Tutorial
86. ES6 Tutorial
91. Flutter Basics
92. Flutter Tutorial
95. Golang Tutorial
96. Graphql Tutorial
100. Hive Tutorial
103. Install Bootstrap
107. Install SASS
109. IPv 4 address
110. JCL Programming
111. JQ Tutorial
112. JSON Tutorial
113. JSP Tutorial
114. Junit Tutorial
115. Kadanes Algorithm
116. Kafka Tutorial
117. Knapsack Problem
118. Kth Smallest Element
119. Laravel Tutorial
122. Linear Gradient CSS
129. Memory Hierarchy
133. Mockito tutorial
134. Modem vs Router
135. Mulesoft Tutorial
136. Network Devices
138. Next JS Tutorial
139. Nginx Tutorial
141. Octal to Decimal
142. OLAP Operations
143. Opacity CSS
144. OSI Model
145. CSS Overflow
146. Padding in CSS
148. Perl scripting
149. Phases of Compiler
150. Placeholder CSS
153. Powershell Tutorial
158. Pyspark Tutorial
161. Quality of Service
162. R Language Tutorial
164. RabbitMQ Tutorial
165. Redis Tutorial
166. Redux in React
167. Regex Tutorial
170. Routing Protocols
171. Ruby On Rails
172. Ruby tutorial
173. Scala Tutorial
175. Shadow CSS
178. Snowflake Tutorial
179. Socket Programming
180. Solidity Tutorial
181. SonarQube in Java
182. Spark Tutorial
189. TCP 3 Way Handshake
190. TensorFlow Tutorial
191. Threaded Binary Tree
196. Types of Queue
197. TypeScript Tutorial
198. UDP Protocol
202. Verilog Tutorial
204. Void Pointer
205. Vue JS Tutorial
206. Weak Entity Set
207. What is Bandwidth?
208. What is Big Data
209. Checksum
211. What is Ethernet
214. What is ROM?
216. WPF Tutorial
217. Wireshark Tutorial
218. XML Tutorial
In today’s connected world, every device on the internet needs a unique ID to communicate. IPv4 addresses serve as these identifiers, ensuring data flows smoothly between devices.
In this tutorial, you’ll learn about IPv4 addresses in computer networks, their structure, classes, range, and why they remain essential for online communication. Understanding IPv4 addresses is key to grasping how networks operate and how the internet truly connects us all. Let’s start by understanding IP first.
Move beyond theory—start creating. Our Software Engineering Courses equip you with practical, job-ready skills through hands-on projects tailored for real-world applications.
IP, short for Internet Protocol, is a fundamental set of rules governing data communication across networks. It assigns a unique address to every device connected to the internet, enabling data packets to be sent and received accurately. An IP address acts much like a street address, allowing information to be directed to and from the correct destination.
IPv4, or Internet Protocol version 4, is the fourth iteration of the IP addressing system and remains the most widely used version on the internet. It is a 32-bit numerical address, typically expressed in a dotted-decimal format, such as 192.168.0.1. Each section of the address consists of 8 bits, ranging from 0 to 255, separated by dots. Here’s an ipv4 address example: 192.168.1.152:
Elevate your programming skills and build expertise for a successful tech career. Explore upGrad programs to master data structures, algorithms, and advanced software development.
IPv4 addressing serves as the backbone of the internet for several compelling reasons. Firstly, its widespread adoption means that most devices and networking equipment are compatible with IPv4. Additionally, its 32-bit address space allows for approximately 4.3 billion unique addresses, which was more than sufficient in the early days of the Internet.
In a computer network, an IPv4 address is a unique numerical identifier assigned to each device connected to the network. When a device, such as a computer, smartphone, or server, connects to a network, it is assigned an IPv4 address. This address consists of a series of four numbers separated by dots, with each number ranging from 0 to 255. For example, 192.168.1.10 is a valid IPv4 address.
IPv4 addresses are used by routers and switches to route data packets from the source device to the destination device. When one device wants to send data to another device on the network, it encapsulates the data in a packet. Routers and switches then use this address information to determine the most efficient path to deliver the packet to its destination.
In local area networks (LANs), such as those within homes or offices, devices are often assigned private IPv4 addresses. These private addresses are reserved for internal use.
The most commonly used private address ranges are 192.168.0.0 to 192.168.255.255, 172.16.0.0 to 172.31.255.255, and 10.0.0.0 to 10.255.255.255.
Also Read: What is TCP/IP Model? Computer Networking Guide
IPv4 addresses can be classified into five different Ipv4 address classes: A, B, C, D, and E. Each class has a specific range of addresses reserved for different purposes.
IPv4 addresses are divided into three main parts: the network part, the host part, and the subnet number. These parts work together to ensure efficient data routing and delivery.
For Windows:
Open the Command Prompt:
Press the Windows key + R to open the Run dialog box.
Type "cmd" and press Enter, or click OK. This will open the Command Prompt.
In the Command Prompt window, type the following command and press Enter:
Look for the network adapter you are using (such as Ethernet or Wi-Fi) and find the "IPv4 Address" under that adapter. It will be listed as "IPv4 Address" followed by the actual IP address in the format of four sets of numbers separated by dots (e.g., 192.168.1.10).
For macOS:
Open the Terminal:
You can find the Terminal application in the Utilities folder within the Applications folder. Alternatively, you can use Spotlight Search (Cmd + Space) and type "Terminal" to launch it.
In the Terminal window, type the following command and press Enter:
Look for your active network adapter (such as en0 for Ethernet or en1 for Wi-Fi) and locate the "inet" section. The IPv4 address will be displayed next to "inet" and will be in the format of four sets of numbers separated by dots (e.g., 192.168.1.10).
Linux (Ubuntu, Debian, etc.):
Open the Terminal:
You can find the Terminal application by searching for "Terminal" in the applications menu.
In the Terminal window, type the following command and press Enter:
Look for your active network adapter (such as eth0 for Ethernet or wlan0 for Wi-Fi) and find the "inet" section. The IPv4 address will be displayed next to "inet" and will be in the format of four sets of numbers separated by dots (e.g., 192.168.1.10).
Please note that the IPv4 address displayed may vary depending on your network configuration. If you are behind a router or using a private network, your public IP address may differ from the one assigned to your device on the local network.
Also Read: What is Network Address Translation (NAT) in Networking? A Ultimate Guide
Recognizing the impending depletion of IPv4 addresses, IPv6 (Internet Protocol version 6) was developed to overcome the limitations of its predecessor. IPv6 uses a 128-bit address format, offering an almost unfathomable number of unique addresses (approximately 340 undecillion!).
IPv6 addresses are expressed in a hexadecimal format, consisting of eight groups of four hexadecimal digits, separated by colons, for example,
2001:0db8:85a3:0000:0000:8a2e:0370:7334.
Also Read: Difference Between IPv4 and IPv6: Complete Guide
The IPv4 address range refers to the set of all possible IP addresses that can be assigned within the IPv4 addressing system. IPv4 addresses are 32-bit numbers, and they are divided into four octets, each represented by eight bits, separated by dots. The range of IPv4 addresses spans from 0.0.0.0 to 255.255.255.255.
However, not all addresses within this range are available for public use. The Internet Assigned Numbers Authority (IANA) has reserved certain address blocks for specific purposes. The main reserved address blocks are:
Private Address Space:
Loopback Address:
Link-Local Address (Automatic Private IP Addressing - APIPA):
Reserved Addresses:
These reserved address blocks serve specific purposes, such as private network usage, loopback for testing purposes, automatic IP addressing when DHCP is not available, and multicast communication.
The remaining addresses within the range are public IP addresses allocated to organizations and devices connected to the global internet.
IPv6 brings significant improvements over IPv4, addressing its limitations and offering enhanced features:
IPv4 addresses have long served as the backbone of the internet, enabling seamless communication between devices worldwide. However, the rapid growth of connected devices has highlighted IPv4’s limitations. IPv6 addresses these challenges, providing a vastly expanded address space and improved functionality. Understanding IPv4 addresses in computer networks, along with IPv6, is essential for network professionals to ensure future-ready, efficient, and uninterrupted internet connectivity.
IPv4 addresses are 32-bit numerical identifiers assigned to devices in a computer network, enabling unique identification and communication across networks. Each IPv4 address allows devices to send and receive data efficiently. Understanding IPv4 addresses in computer networks is essential because they form the basis of routing, addressing, and network configuration. Without proper IPv4 addressing, devices cannot locate each other, making network communication impossible.
IPv4 addresses consist of four octets separated by periods, with each octet representing 8 bits, making a total of 32 bits. For example, 192.168.0.1 is a typical IPv4 address. This structure allows networks to categorize addresses into network and host portions, enabling proper routing. Each octet can have values from 0 to 255, allowing over 4 billion unique addresses in the IPv4 system.
Public IPv4 addresses are globally unique and required for devices to access the internet. Private IPv4 addresses, like 192.168.x.x or 10.x.x.x, are reserved for local networks and cannot be routed over the internet. ISPs assign public addresses dynamically or statically, while private addresses can be reused across multiple networks. Knowing the distinction is crucial for network design and security.
IPv4 addresses are divided into classes A, B, C, D, and E to designate network and host portions. Class A supports very large networks, Class B supports medium networks, and Class C is for smaller networks. Class D is reserved for multicast traffic, while Class E is experimental. Understanding these classes helps network administrators allocate addresses efficiently and manage routing.
Subnetting divides a network into smaller segments, called subnets, to improve management, security, and performance. It allows network administrators to allocate IPv4 addresses efficiently, reducing wastage. By using subnet masks, administrators can control how many devices belong to a subnet while keeping traffic localized and organized.
A subnet mask separates the network portion of an IPv4 address from the host portion. For instance, 255.255.255.0 indicates that the first three octets represent the network and the last octet identifies hosts. Subnet masks enable efficient IP allocation, facilitate routing, and help divide larger networks into manageable segments.
Static IPv4 addresses are manually assigned to a device and do not change over time, ideal for servers and network hardware requiring consistent addressing. Dynamic IPv4 addresses are automatically assigned using DHCP and can change periodically. Dynamic addressing simplifies network management, especially for large networks with many devices.
Network Address Translation (NAT) allows multiple devices in a private network to share a single public IPv4 address for internet communication. NAT conserves public IPv4 addresses and provides an additional layer of security by masking internal IP addresses from external networks. It’s widely used in homes, offices, and enterprise networks.
The Dynamic Host Configuration Protocol (DHCP) dynamically allocates IPv4 addresses to devices in a network. When a device connects, it requests an IP from the DHCP server, which assigns an available address from a pool. This ensures efficient management, prevents conflicts, and allows devices to join the network without manual configuration.
IPv4 addresses identify devices logically on a network, enabling data routing across networks. MAC addresses are hardware identifiers burned into network interface cards, allowing local identification of devices. Together, MAC addresses manage data delivery within a local network, while IPv4 addresses handle communication across networks and the internet.
Devices can obtain IPv4 addresses either manually (static IP) or automatically through DHCP (dynamic IP). Dynamic allocation is more common in large networks, allowing devices to join seamlessly. Static IPs are reserved for servers, network printers, or devices requiring consistent connectivity. Understanding this is key to configuring IPv4 addresses in computer networks.
Yes, private IPv4 addresses can be reused in multiple networks since they are not globally unique. Public IPv4 addresses must remain unique across the internet to prevent conflicts. NAT technology further allows reuse of private addresses internally, reducing the consumption of the limited pool of public IPv4 addresses.
Subnetworks divide large networks into smaller sections to manage IPv4 addresses efficiently. Each subnet receives a portion of the main address range, reducing address wastage and improving network performance. Subnetting also enhances security by isolating traffic between subnets and controlling broadcast domains.
Classless Inter-Domain Routing (CIDR) notation expresses the network portion of an IPv4 address with a suffix, like /24. CIDR allows flexible subnetting and more efficient allocation of IPv4 addresses, overcoming the limitations of traditional class-based addressing. It is essential for modern network design.
Routers examine the destination IPv4 address in each packet and use routing tables to determine the best path. They forward packets to the appropriate network segment. Correct understanding of IPv4 addresses ensures proper routing configuration and avoids misdelivery of data in computer networks.
IPv4 addresses enable devices to locate and communicate with each other across networks. Protocols like TCP/IP rely on these addresses for packet delivery. Every web request, email, or file transfer requires correct IPv4 addressing to ensure accurate and timely delivery.
Subnetting prevents IPv4 address wastage by creating smaller, more manageable networks. It allows the same network to host multiple subnets, improving utilization of available addresses while supporting network segmentation, performance, and security requirements.
Firewalls inspect incoming and outgoing traffic based on IPv4 addresses, allowing or blocking specific ranges. This prevents unauthorized access, mitigates attacks, and ensures sensitive data stays within protected network boundaries, highlighting the importance of IPv4 addresses in computer network security.
ISPs use NAT, dynamic allocation, and reuse of private addresses to conserve IPv4 addresses. They also encourage the gradual transition to IPv6, which provides virtually unlimited addresses, while maintaining legacy IPv4 support for older systems.
Despite IPv6 adoption, IPv4 addresses remain essential due to compatibility with legacy systems and widespread deployment. Understanding IPv4 addresses in computer networks is critical for network engineers, system administrators, and developers to maintain, troubleshoot, and optimize existing network infrastructures.
FREE COURSES
Start Learning For Free
Author|900 articles published
Recommended Programs