On this page
Dedicated, static and shared are different things
Shared means many people go out through one address, as on most VPN services. Dedicated means the address is yours alone. Static means it doesn't change. A dedicated address is usually static as well, but a static address isn't always dedicated, and vice versa.
An ordinary VPN service address
Who uses itMany customers at once
Does it changeOften, between connections
What sites seeA hosting network, often on lists of VPN addresses
A dedicated IP from a VPN service
Who uses itYou alone, on the service's server
Does it changeUsually not
What sites seeA hosting network; the service knows it is you
Your own server, a VPS
Who uses itYou and whoever you share it with
Does it changeStays with the server; in a cloud, reserve it
What sites seeA hosting network: your host's
A static IP from your home provider
Who uses itYour home
Does it changeNo
What sites seeYour home provider and its country
What a dedicated address helps with
- Fewer captchas. Nobody else's bots share it, so Google and others ask far less often than on a busy VPN address.
- The same address at every login. Sites that remember where you log in from see one address in one country, not a new one each time that strangers also use. It is still a hosting address: a service that refuses those won't change its mind.
- Allow-lists. Admin panels, SSH, databases and company services are often open only to listed addresses. A fixed address of your own can go on that list; a shared one can't, since it would let everyone on the VPN service in.
- Incoming connections. A server with a public address of its own accepts connections, and it can pass a port on to a device inside the tunnel, even one at home behind the provider's NAT. How, see below.
- Your own reputation. What comes from the address comes from you and those you share it with. A cheap address may still carry its previous owner's history, and many hosts will change it.
What it doesn't do
- It doesn't look like a home connection. The address belongs to a hosting company's network, and these networks are public: AWS and Oracle, for example, publish their address ranges as files anyone can download. Services that block hosting networks block a dedicated address the same way.
- It doesn't hide the VPN from a site that checks who owns the network. It only takes away the crowd of strangers.
- It isn't anonymity. One address, one person: everything you open is tied to the same IP with nobody else behind it. A shared address hides you among many people, a dedicated one doesn't.
- One server, one country. Another country means another server and another address.
- The host still sees the server's traffic, as any network does, and knows from the payment whose server it is.
Keep the address from changing
At an ordinary VPS host the address comes with the server; whether it survives a reinstall or a move to another plan, the host's terms say. In the big clouds the default public address is temporary, and if it matters, you reserve a fixed one.
AWS
The ordinary public addressReleased when the machine is stopped; a new one on start
The fixed oneAn Elastic IP, billed like every public IPv4 there, $0.005 an hour
Google Cloud
The ordinary public addressEphemeral: released when the machine is stopped or deleted
The fixed oneA reserved static external address, kept until you release it
Oracle Cloud
The ordinary public addressEphemeral: stays while the machine exists, stopped or not, and goes with it
The fixed oneA reserved public IP, kept until you delete it and movable to another machine
- When the address does change, every profile and link on your devices still points to the old one, and an allow-list at work too. With a domain name in place of the address, only its DNS record has to change.
Port forwarding through your own VPS, by hand
VPN services that sell port forwarding open a port on their address and pass what comes to it down the tunnel to you. On your own server you do the same with one rule: the server takes a connection on a port of its public address and sends it to your device's address inside the tunnel. It is for a program that has to accept connections, such as a game server, a P2P program or remote access to a computer, when the device itself has no public address.
This is a manual server setup, not something an app does for you: WireGuard on Ubuntu or Debian, the server at 10.8.0.1, the device at 10.8.0.2, the forwarded port TCP 25565. eth0 is the server's outside interface: ip route shows its name after dev in the default line.
[Interface]
PrivateKey = SERVER_PRIVATE_KEY
Address = 10.8.0.1/24
ListenPort = 51820
PostUp = iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -o eth0 -j MASQUERADE
PostUp = iptables -t nat -A PREROUTING -i eth0 -p tcp --dport 25565 -j DNAT --to-destination 10.8.0.2:25565
PostUp = iptables -I FORWARD -i eth0 -o %i -p tcp -d 10.8.0.2 --dport 25565 -j ACCEPT
PostDown = iptables -t nat -D POSTROUTING -s 10.8.0.0/24 -o eth0 -j MASQUERADE
PostDown = iptables -t nat -D PREROUTING -i eth0 -p tcp --dport 25565 -j DNAT --to-destination 10.8.0.2:25565
PostDown = iptables -D FORWARD -i eth0 -o %i -p tcp -d 10.8.0.2 --dport 25565 -j ACCEPT
[Peer]
PublicKey = DEVICE_PUBLIC_KEY
AllowedIPs = 10.8.0.2/32The first PostUp is the usual way out to the internet, the next two are the forwarding: DNAT changes the destination, the FORWARD rule lets it through. For UDP write -p udp. Forwarding has to be on, net.ipv4.ip_forward=1, as on any VPN server. Apply with systemctl restart wg-quick@wg0.
[Peer]
PublicKey = SERVER_PUBLIC_KEY
Endpoint = SERVER_IP:51820
AllowedIPs = 0.0.0.0/0
PersistentKeepalive = 250.0.0.0/0 sends the answers back through the tunnel. PersistentKeepalive keeps the path open while nobody is connecting.
nft add table ip fwd
nft 'add chain ip fwd prerouting { type nat hook prerouting priority dstnat; }'
nft add rule ip fwd prerouting iif eth0 tcp dport 25565 dnat to 10.8.0.2:25565Rules added this way are gone after a reboot unless they are in /etc/nftables.conf. If a forward chain has policy drop, it needs an accept for the port too.
Test-NetConnection SERVER_IP -Port 25565
nc -vz SERVER_IP 25565The first line is Windows PowerShell, the second macOS or Linux. The program on the device has to be running and allowed through the device's own firewall.
- Open the port in the cloud as well. Its firewall (a security group, a security list, a VPC firewall rule) has to let TCP 25565 in, and UDP 51820 for WireGuard itself.
- If the device sends only part of its traffic through the tunnel, answers to strangers leave by its usual route and the connection breaks. Either keep
AllowedIPs = 0.0.0.0/0, or add one more rule on the server:iptables -t nat -A POSTROUTING -o wg0 -p tcp -d 10.8.0.2 --dport 25565 -j MASQUERADE. Then the device sees every visitor as 10.8.0.1. - Everything that comes in arrives at your server's address. Complaints about it go to the host, and from the host to you.
A static IP from your provider, or a dedicated VPN IP
They do different jobs. A static address from your home internet provider is the address of your home: through it, with port forwarding on the router, you reach your home network from outside, and sites see your provider and your country. It hides nothing from sites; it makes home reachable. If the provider keeps customers behind CGNAT, it is the public address that matters, not the static one: without a public address, incoming connections don't reach home at all.
A dedicated VPN address is somewhere else, in a datacenter, often in another country. Sites see it instead of your home address, and it makes nothing at home reachable unless you forward a port through it, as above. To reach home from a phone you need a public address at home or a VPS in the middle; to go out to the internet under one fixed address of your own, your own server is enough.