I have a VPS in Amsterdam that has a /64 network of IPv6 addresses assigned to it, with unmetered internet access enabled, plus an IPv4 also unmetered..
I'm now wandering if it is possible to not only create a "simple" IPv4 "normal" VPN server, but also a 4to6 gateway, meaning that everyone that connects to my VPN server, will access the internet in IPv6 instead and have just the VPN tunnel in IPv4 mode;
Also meaning that every one of my devices that connects to the VPN will have a single, unique IPv6 address assigned and this would be for example to be able to access my home machine via IPv6 accessing the VPS of the VPN server firstly and then being re-routed over the IPv4 VPN tunnel to access the real machine "behind" that IPv6, all software based with the VPN.

It would be great to have auto assignment of IPv6 addresses the first time a certain device connects and to save that IPv6 in a config file to that and that device only for the aforementioned reasons; but I don't mind creating a config file myself and adding all the devices manually...

Is it possible / is there some online guides (digitalocean or something like that) that I can follow step by step to install the VPN server software in my VPS, enable all the certificates, find a way to differentiate every single device that connects in not by IP but something else (I don't even mind creating 7 certificates, one for each device that will use the VPN), and configuring the config file for the 6to4 tunnel?


I am going to assume that the mention of 4to6 and 6to4 in your question is a mistake and you really meant 6in4. However if you are using a proper VPN you will however not need 6in4.

The main difference between VPN and 6in4 is that 6in4 is just a tunnel and VPN is a tunnel with a cryptographic layer for security. A VPN can run both IPv4 and IPv6 on the inside of the tunnel regardless of whether the tunnel itself runs over IPv4 or IPv6.

How to configure that depend on the VPN you are using.

The real question here is whether your VPS actually has enough addresses to do what you want. You say you have a /64, but that's not sufficient information to know whether that VPS is suitable.

In order to run a correctly configured VPN you need both a link prefix and a routed prefix. The link prefix need to be a /64. The routed prefix need to be /64 or shorter. Based on the information in the question I'd guess a /56 or /60 would be suitable.

Many VPS providers by default will give you a /64 link prefix and no routed prefix. The link prefix can be either dedicated to you or shared between multiple customers. Some VPS providers will give you a routed prefix if you ask for one, some VPS providers just won't give you a routed prefix.

  • Comments are not for extended discussion; this conversation has been moved to chat. – DavidPostill Jan 12 at 20:26
  • Sorry @DavidPostill, thanks for the authorization to post on the live chat for the information sharing in order to properly answer the asked goal. – BJPGameVideosITA Jan 12 at 22:29

Your Answer

By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Not the answer you're looking for? Browse other questions tagged or ask your own question.