Skip to content

Instantly share code, notes, and snippets.

@jonocairns
Last active October 16, 2023 14:33
Show Gist options
  • Star 15 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save jonocairns/18162fbd6c85211a00dbfce0906c88f4 to your computer and use it in GitHub Desktop.
Save jonocairns/18162fbd6c85211a00dbfce0906c88f4 to your computer and use it in GitHub Desktop.
0) Go to https://mullvad.net/en/download/#linux <-- Latest Link when I made this guide or just go to your mullvad account page
1) Download your mullvad VPN files by clicking "GenerateOpenVPN configuration files" . Make sure to keep "Use IP addresses" and "Connect via our bridges" left unchecked
2) Unzip the downloaded file.
3) Move all four files (you should have four) to appdata/deluge/openvpn
3a) change the file extension of mullvad_<whatever region you selected>.conf to mullvad_<whatever region you selected>.ovpn
3b) Open mullvad_<whatever region you selected>.ovpn with a text editor and add the following lines to the bottom:
pull-filter ignore "route-ipv6"
pull-filter ignore "ifconfig-ipv6"
3c) save the file.
4) In your deluge container, edit the following settings:
4a) Key 1 (VPN_ENABLED) should be set to "yes"
4b) Key 2 (VPN_USER) should be your Mullvad account number; a 16 digit number you received when you set up your Mullvad account which also can be found in mullvad_userpass.txt.
4b+)Do not include the "m" as shown in the .txt file, just the 16 digit account number.
4c) Key 3 (VPN_PASS) same account number as Key 2, no "m".
4d) Key 4 (VPN_PROV) set to "custom"
4e) Key 6 (STRICT_PORT_FORWARD) set to "yes"
4f) Key 8 (LAN_NETWORK) put the first 3 numbers of your routers IP (most likely 192.168.1) followed by .0/24 (example "192.168.1.0/24")
5) Apply and restart deluge
For faster Downloads, Mullvad supports port forwarding. This can be done by:
6) Go to the mullvad.net homepage, and under your account, you'll see "Manage Ports and Wireguard keys"
6a) It was this link when I created the guide: https://mullvad.net/en/account/ports/
7) Click "add port" and then copy the port that it spits out.
8) Go to the deluge UI and under preferences / network, change "Incoming Port" to:
8a) Uncheck "Use Random Port" and put in the port you copied.
9) You're done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment