Setting up WireGuard® VPNUK on DD-WRT Routers
Follow these steps to configure a WireGuard® VPN connection on your DD-WRT router using VPNUK.
WireGuard® configuration download
Please login using the VPN login username and password from the vpn account you would like to configure.
Click Here to download your WireGuard® configuration file, which is compatible with all devices.
1: Open your configuration file.
- Click Here to download the WireGuard® configuration file (
.conf). - Open the
.conffile in Notepad or a text editor and take note of the following details:- Private Key
- Public Key
- Allowed IPs
- Endpoint (VPNUK Server Address)
- Port
2. Enable WireGuard® on DD-WRT Router
- Log in to your DD-WRT router via web interface.
- Navigate to Services > VPN.
- Under WireGuard® VPN, click Enable.
- Set the following parameters:
- Private Key: (Paste your Private Key from the WireGuard®
.conffile) - Listen Port:
59851(VPNUK WireGuard® port) - MTU:
1420
- Private Key: (Paste your Private Key from the WireGuard®
- Click Save and Apply Settings.
3. Add Peer (VPNUK Server)
- Under WireGuard® Configuration, click Add Peer.
- Enter the following details:
- Public Key: (Paste the Public Key from your
.conffile) - Allowed Address:
0.0.0.0/0 - Endpoint Address: (Enter the VPNUK server address from your
.conffile) - Endpoint Port:
59851 - Persistent Keepalive:
25
- Public Key: (Paste the Public Key from your
- Click Save and Apply Settings.
4. Configure Routing for WireGuard® VPN
- Navigate to Setup > Advanced Routing.
- Click Add Route and set:
- Destination IP:
0.0.0.0/0 - Gateway:
wg0(WireGuard® interface)
- Destination IP:
- Click Save and Apply Settings.
5. Enable and Verify VPN Connection
- Navigate to Status > WireGuard®.
- Check the Handshake Status – it should say Active.
- To confirm the connection, check your new IP address by visiting: https://www.ipaddress.com/
Your IP should now match your unique VPNUK IP.
Enjoy Secure VPN Access with VPNUK & WireGuard® on DD-WRT Routers
Did this guide help? Please provide us with feedback here or share it with others looking for a secure VPN setup on DD-WRT Routers!
Optional WireGuard® Settings for DD-WRT Routers
1. Enable Auto-Start for WireGuard® VPN
To ensure WireGuard® automatically reconnects after a router reboot or disconnection, follow these steps:
- Log in to DD-WRT via Web Interface.
- Navigate to Administration > Commands.
- In the Startup Commands section, enter the following script: sleep 10; wg-quick up wg0) &
- Click Save Startup.
- Reboot your router to apply the changes.
This ensures that WireGuard® reconnects automatically every time your router starts.
2. Selective Routing (Policy-Based Routing for Specific Devices)
By default, all devices connected to your DD-WRT router use the VPN tunnel. If you want only certain devices to route through VPNUK’s WireGuard® VPN, follow these steps:
Step 1: Enable Policy-Based Routing
- Go to Setup > Advanced Routing.
- Click Add Route and enter:
- Destination:
0.0.0.0/0 - Gateway:
wg0(WireGuard® interface)
- Destination:
- Click Save & Apply Settings.
Step 2: Assign Specific Devices to the VPN
- Go to Services > VPN.
- In the WireGuard® Configuration, locate Policy-Based Routing.
- Enter the local IP addresses of devices you want to use the VPN.
- Click Save & Apply Settings.
Now, only selected devices will use WireGuard®, while all others remain on the regular internet connection.
Troubleshooting Common Issues
Cannot connect to VPNUK servers?
Ensure the WireGuard® server address and keys are correct.
We recommend downloading a new config file if the connection stops working.
Restart your DD-WRT router and try again.
Verify that UDP Port 59851 is open on your network.
VPN is connected, but no internet?
Go to Firewall NAT rules and ensure masquerade is enabled.
Check IP Routes to confirm wg-vpn is set as the default gateway.
“WireGuard” and the “WireGuard” logo are registered trademarks of Jason A. Donenfeld. WireGuard® is available and should always be updated from the developers website at wireguard.com