(or: living in the present, trapped in the past)
IPv6 has been around for roughly forever™, yet in the year 2026 GitHub still behaves like the internet ends at 0.0.0.0/0.
If you are running an IPv6-only host (because you enjoy modern networking) you may have noticed that GitHub is practically unreachable.
git clone fails and HTTPS goes nowhere.
Here are two ways to deal with this time-travel issue.
Option 1: The /etc/hosts + proxy hack
One straightforward workaround is to route GitHub traffic through an IPv6-accessible proxy that speaks IPv4 on your behalf. Daniel Winzen provides a public proxy thats exposes a public proxy that exposes GitHub services over IPv6.
Because DNS is a suggestion and /etc/hosts is the law, we simply override GitHub’s hostnames there:
2a01:4f8:c010:d56::2 github.com
2a01:4f8:c010:d56::3 api.github.com
2a01:4f8:c010:d56::4 codeload.github.com
2a01:4f8:c010:d56::6 ghcr.io
2a01:4f8:c010:d56::7 pkg.github.com npm.pkg.github.com maven.pkg.github.com nuget.pkg.github.com rubygems.pkg.github.com
2a01:4f8:c010:d56::8 uploads.github.com
2606:50c0:8000::133 objects.githubusercontent.com www.objects.githubusercontent.com release-assets.githubusercontent.com gist.githubusercontent.com repository-images.githubusercontent.com camo.githubusercontent.com private-user-images.githubusercontent.com avatars0.githubusercontent.com avatars1.githubusercontent.com avatars2.githubusercontent.com avatars3.githubusercontent.com cloud.githubusercontent.com desktop.githubusercontent.com support.github.com
2606:50c0:8000::154 support-assets.githubassets.com github.githubassets.com opengraph.githubassets.com github-registry-files.githubusercontent.com github-cloud.githubusercontent.com
After that, you can use GitHub as usual.
If you don’t want to touch your /etc/hosts file, you can also use the proxy explicitly.
Via HTTPS
git clone https://danwin1210.de:1443/DanWin/le-chat-php.git
or via SSH
git clone git@github-ipv6-proxy.danwin1210.de:DanWin/le-chat-php.git
Fair warning: By using the HTTPS approach, you are man-in-the-middle’ing yourself on purpose (SSL is broken in the middle. Do not transfer any sensitive information over this! You’ve been warned!).
Option 2: NAT64 / DNS64
In short: your IPv6-only machine asks for a AAAA record, the DNS64 server makes one up based on the IPv4 address, and NAT64 magically translates your IPv6 packets into IPv4 on the fly.
It’s like sending a letter in Elvish and having a goblin deliver it in Klingon. Somehow, the message still arrives, but only if the magical translator
is awake and caffeinated. Not every network has this wizardry, but when it works, you can access
IPv4-only services without messing /etc/hosts.
If your network does not support NAT64/DNS64 (and you don’t feel like doing it yourself), you can use a public service like nat64.net.
The easy way is to throw their listed nameservers straight into your /etc/resolv.conf.
However, this means all your DNS queries will now pass through their servers.
If that is a dealbreaker, grab the first DNS server from their website (at the time of writing, it’s 2a01:4f8:c2c:123f::1)
and we’ll use the magic of /etc/hosts again. We can query the fake AAAA entry for GitHub directly from their server and
append it to our configuration with a quick one-liner:
dig +short github.com AAAA @2a01:4f8:c2c:123f::1 | sed -e 's/$/ github.com/g' >> /etc/hosts
Once that’s done, github.com should be usable as normal.