Convert IPV4 to binary
Result
IPv4 (Internet Protocol version 4) is the most used protocol for transmitting data around networks on the internet. IPv4 is the fourth iteration of the IP protocol and enables connected devices to share information over the internet. IPv4 has a 32-bit address space allowing around 4.3 billion unique IP addresses. An IPv4 address consists of four octets, each octet is eight bits in length. The number of new devices connecting to the internet each year is on the rise. The limited address space of IPv4 has called for the gradual adoption of IPv6 126-bit addresses, which has a significantly larger address space compared to IPv4. Broadcasting, unicating, and multicast are also supported by IPv4. The packets of an IPv4 split into a payload and a header. The payload is the data that is being transmitted where the header contains the destination address and source address.
Octet is a grouping of eight binary bits, the same as a byte. But the word octet is used in networking to avoid confusion with storage (byte). An IPv4 address is made up of four octets separated with a dot. In total, an IP address comprises 32 binary bits. In binary, the range of an octet starts at 00000000 up to 11111111. In Decimal, an octet can have a value from 0 up to 255.
Fig.1 An Example of an IP Address with four octets.
There may be other methods out there that you could use to convert an IP address to binary. But there are two tried and tested methods: division and table method. In this article, we will discuss how to convert an IP address using the division method. Which one you choose depends on you, but they will have the same outcome if the methodology is applied correctly.
To convert an IP address of 193.168.67.33 using division, you simply continually divide the octet by two until the quotient (answer of the division) reaches zero. During each division iteration, the remainder should be noted. An IPv4 address consists of four octets, each separated with a dot between them. These octets will be converted separately to one another. Start with the first octet, which is 193, and divide it by 2, which results in 193/2 = 96 with a remainder of 1. So the next step would be noting the remainder, which is 1, and then taking the quotient from the first step, which is 96, then divide that by two. Continue to repeat each step again until the quotient is zero. Then reverse the order list of eight remainders that were noted during the division to reverse the binary equivalent of the integer. See the steps below and compare your answers:
When you reverse the order of the remainders you get 11000001, so 193 is 11000001 in binary. Repeat the same steps for the next octet, which is 168, and repeat for octet 67 and 33. In the end, your answer should exactly match “11000001.10101000.01000011.00100001”.