Compact and 0x-prefixed hex
Generate a compact eight-character IPv4 hex value and the same value with a 0x prefix for code, reports or technical notes.
Input Rules
Enter exactly four decimal octets separated by dots. Each octet must be a whole number from 0 to 255. IPv6 and hostnames are intentionally rejected.
Octets
0
Hex Length
0
Class
-
Private
-
Validation
Compact Hex
-
0x Hex
-
Byte Separated
-
Decimal Integer
-
Byte Breakdown
| # | Decimal | Hex | Binary |
|---|---|---|---|
| No conversion yet. | |||
Report
-
IPv4 conversion
This IP to Hex converter turns a dotted decimal IPv4 address into hexadecimal formats used in packet notes, embedded networking, firewall documentation and low-level debugging. Enter one IPv4 address, choose uppercase or lowercase output, pick a byte separator, then review compact hex, 0x-prefixed hex, byte-separated hex, decimal integer output and the byte table. Each octet is validated and mapped to one two-character hex byte, so the result stays tied to the original IPv4 address instead of guessing from free-form text.
Generate a compact eight-character IPv4 hex value and the same value with a 0x prefix for code, reports or technical notes.
Choose no separator, colon, hyphen, dot or space output so each IPv4 octet remains readable as its own hex byte.
Strict IPv4 validation rejects IPv6, hostnames, leading zeroes and invalid octets. The table shows every byte as decimal, hex and binary.
192.168.1.1.Hex bytes are easier to compare with packet captures, protocol docs and raw byte dumps than dotted decimal values.
Use compact or byte-separated hex when documenting ACLs, firmware settings, embedded network fields or config formats that expect hex bytes.
Compare hex bytes with the IP to Binary converter and CIDR Calculator when checking masks and octet boundaries.
Export a repeatable report that includes the original IPv4 address, compact hex, prefixed hex, decimal integer and byte table.
Use exactly four decimal octets separated by dots. Each octet must be a whole number from 0 to 255, with no leading zeroes.
192.168.1.1 becomes compact hex C0A80101, prefixed hex 0xC0A80101 and byte-separated hex such as C0:A8:01:01.
Each IPv4 octet maps to one hex byte: 192 is C0, 168 is A8, and 1 is 01. The table keeps that mapping visible.
This page performs local numeric conversion for IPv4 dotted decimal input only. It does not support IPv6, resolve hostnames, run DNS lookups, check ownership, geolocate addresses, ping hosts, scan ports or confirm uptime. The class-style and private-range labels are quick interpretation aids, not routing policy. Because the conversion runs in browser JavaScript, the IP address does not need to be sent to a server to calculate compact, prefixed or byte-separated hex output.
It accepts one dotted decimal IPv4 address with exactly four octets. Each octet must be a whole number from 0 to 255.
Each decimal octet is converted to one two-character hex byte. For example, 192 becomes C0, 168 becomes A8, 1 becomes 01 and 1 becomes 01.
Compact hex joins the four bytes into one value such as C0A80101. Byte-separated hex keeps the bytes visible with a separator such as C0:A8:01:01.
Yes. You can switch the hex case, view the 0x-prefixed output, and choose a byte separator for the separated value.
No. This page converts IPv4 dotted decimal addresses only. IPv6 uses 128-bit notation and is outside this converter's scope.
No. The conversion runs locally in your browser. It does not perform DNS lookup, geolocation, ownership lookup, ping, port checks or uptime testing.