Set up a ForestVPN bridge on a rented server
Make a bridge on a small cloud server in about 5 minutes. Paste one setup line, confirm the address in the app, and you are done.
Not yet verified on hardware. This page describes the steps the app shows. Nobody has yet followed them end to end on every kind of server listed here.
A bridge is a small program on a server you rent. It passes your encrypted connection to ForestVPN, and it is a way in, never a location. This page takes you from nothing to a bridge the app shows as Ready.
- Make a setup line in the app.
- Create a small Linux server and paste the line.
- Confirm the address in the app.
What you get
A bridge your devices use by themselves when it is the better way in. It costs nothing on any ForestVPN plan and does not count toward your 10 devices. Sites still see the location you choose.
Before you start
- A host account. You need an account at a company that rents small servers. Choose where to host a bridge compares them by situation.
- A small server. Ubuntu or Debian is the easy choice. The smallest size is enough.
- 5 minutes. The server needs about a minute to start and check in.
- A ForestVPN account. Bridges belong to your account. If you have none, create one in the app first.
- A public address. The server must have its own public internet address, not one shared between many customers. A rented server has one.
Steps
-
In the app open Account, Bridges, Add a bridge, then On a server I rent. The app shows a setup line, a cloud-init block and a Docker command. Keep this screen open.
Copy exactly what the app shows. The setup code starts with
FVR1-, and the app puts it inside single quotes on purpose. -
At your host, create the server. Pick Ubuntu or Debian and the smallest size.
-
Paste the cloud-init block into the box called User data or Cloud-init, then create the server. Cloud-init is a note you hand the host; the server reads it the first time it starts and runs it for you, so you never open a terminal. The block has this shape; use the one from the app, not this one.
What the cloud-init block looks like
#cloud-config runcmd: - curl -fsSL https://routers.fvpn.net/bridge.sh | sh -s -- 'FVR1-...' -
If your host has its own firewall for the server (Oracle calls it a security list, AWS a security group), open the UDP port the app shows and TCP port 443. A port is a numbered door into the server, and UDP and TCP are two ways of using one. Without this, the bridge runs but nothing reaches it.
-
Already have a server? Open its console in your host's panel, or connect with SSH (the standard way to type commands on a server from your own computer), paste the one line from the app and press Enter. It looks like this.
The one line, run on the server
curl -fsSL https://routers.fvpn.net/bridge.sh | sudo sh -s -- 'FVR1-...' -
Docker comes last, under Other ways in the app. Use it when the server is a NAS or a machine that already runs Docker.
The Docker command (the app fills in the port and the code)
docker run -d --name forestvpn-bridge --restart unless-stopped \ -p <udp-port>:<udp-port>/udp -p 443:443/tcp \ -v forestvpn-bridge:/var/lib/forestvpn \ suquant/fvpn:latest bridge serve --join 'FVR1-...' -
Back in the app, wait. About a minute after the server starts, the app says it found your bridge and shows its name and address. Check that address against your host's control panel, then choose Use this bridge. If the address is not the one your host shows, choose This isn't mine and make a new line.
-
The app checks the bridge from your network, asks you to name it, and shows Done.
Check it worked
- The app shows your bridge as Ready. Ready means it answered from this network within the last 24 hours.
- On the server, run
fv bridge status. It shows the state, the ports it has open, the address and the package version. - If the app says it cannot reach the bridge, go to Fix a bridge that is not working. On the server,
fv bridge doctorprints one line per check and a fix for each failure.
The setup line works once and expires after 24 hours. Anyone who has it can set up a bridge for you, so do not post it anywhere.
Undo it
Remove the bridge in the app, then uninstall the software on the server and delete the server at your host to stop paying. The steps are in Remove a bridge.
If something is wrong
Start with Fix a bridge that is not working. The two most common causes are a firewall at your host that has not opened the two ports, and a setup line that has expired.
Limits
- A public address is required. A bridge cannot work behind a shared internet address. The app says so in plain words.
- A bridge in your own country helps only if its path abroad is open. The bridge still has to reach ForestVPN's servers from where it runs. A server that cannot do that cannot carry your connection.
- Five bridges per account. Remove one to add another.
- Updates. A bridge installed from ForestVPN's own package source updates itself. One installed from GitHub cannot; the app shows a new line when it needs one.