About the IP Address to Hex Converter
An IPv4 address can be written in hexadecimal, which some low-level tools, obfuscated URLs and packet dumps use. This tool converts each octet to two hex digits and joins them with a 0x prefix, so 192.168.1.1 becomes 0xC0A80101. Convert several at once, one per line.
To reverse, use Hex to IP; for the binary form used in subnetting, IP to Binary.
Two hex digits per octet is a fixed width, and that is the appeal: eight characters every time, in the same byte order the address travels in on the wire. Open a packet capture and the source and destination addresses sit in the IPv4 header as those same four bytes each, at offsets 12 and 16, so the value here can be matched against a dump byte for byte with no conversion in your head.
The security angle is worth knowing. Browsers and many HTTP libraries accept 0xC0A80101 in a URL and resolve it to 192.168.1.1, and the plain integer and octal forms work the same way, which is a standard trick for disguising a link target or getting past a filter that only recognises dotted quads. A hex host in a link is a signal worth checking rather than trusting.
How to use
- Paste IPv4 addresses, one per line.
- Copy the hex values.
Common questions
- Why would an IP be in hex?
- Packet analysers and some URL obfuscation use hex. Browsers even accept hex IPs in links.
- Is there a 0x prefix?
- Yes, the output is prefixed with 0x.
- IPv6?
- This is IPv4. IPv6 is already largely hexadecimal; use the IPv6 tools.