thiagowfx's avatar

¬ just serendipity 🍀 (not just serendipity)

What is my IP?

• 235 words • 2 min • updated

⚠️ This post is over one year old. It may no longer be up to date or relevant. Opinions may have changed.

This post contains a small handful of distinct services to query your machine external IP address.

Google #

URL: https://www.google.com/search?q=what+is+my+ip

As of this writing, this doesn’t work on duckduckgo: https://duckduckgo.com/?q=what+is+my+ip. I suppose this is related to their philosophy of not tracking their users.

This is the easiest method when you have a web browser as you do not need to memorize any URL.

I can haz ip #

URL: https://icanhazip.com/

shell
$ curl icanhazip.com
NNN.NNN.NNN.NNN

I love the simplicity of I can haz ip. It just returns your IP address in plain text, nothing else. It also works from the web browser. You can find details about it in the FAQ. TL;DR: It was an open source pet project of a single person (Major Hayden), then it was eventually bought by Cloudflare as it immensely grew.

It’s also possible to query your IPv6 address in case you have one:

shell
$ curl -6 icanhazip.com

IPInfo #

URL: https://ipinfo.io/

IPInfo returns structured data beyond just your IP address. There are several similar services that do this, for example, What is my IP? and https://ifconfig.co/, however IPInfo is the cleanest one I have seen.

ping.eu #

URL: https://ping.eu/

I’ll also give an honourable mention to ping.eu as it contains a small handful of utilities to check for things like Traceroute, DNS, whois, port check, etc.

ifconfig.io #

Update (2024-07-11): Add ifconfig.io.

URL: https://ifconfig.io/

shell
$ curl ifconfig.io