Skip to content

Gluetun

A Docker container that routes your traffic through a VPN from many providers, with built-in proxies.

Stars
16k
Forks
647
Licence
MIT
Language
Go
Last update
8 days ago
Type
App

What it is

Gluetun is a small VPN client that runs inside a Docker container. You point it at a commercial VPN provider such as Mullvad, NordVPN or Surfshark, and it sends the container's traffic through that VPN. It also includes a firewall kill switch, DNS over TLS, optional ad and malware hostname blocking, and HTTP, SOCKS5 and Shadowsocks proxies that other programs can use.

  • Run a torrent or download container so all its traffic goes through the VPN
  • Give other containers access to the internet only via a VPN using the built-in proxies
  • Route LAN devices through the VPN by connecting them to the container
  • Use the built-in HTTP or Shadowsocks proxy from other apps

Great for

  • People who want one Docker container to run traffic through a VPN for other containers
  • Users of providers listed in the README who want OpenVPN or WireGuard
  • Setups where other apps should reach the internet only through a VPN
  • Home-server users who want to route LAN devices through a VPN

Not ideal for

  • People who need a simple desktop VPN app with a graphical interface, since setup is done through Docker and environment variables
  • Users of VPN providers not listed in the README, unless they are comfortable with the custom provider option
  • Anyone who cannot run Docker or grant the container the NET_ADMIN capability and /dev/net/tun device
Step-by-step guide: how to use GluetunInstall, first run, examples, tips and FAQs

How to get it

  1. 1

    Run with Docker

    You'll need: Docker · A VPN subscription with a supported provider

    Run with docker-compose (save the README example as docker-compose.yml first)

    docker compose up -d
  2. 2

    Run it

    • Create a docker-compose.yml based on the README example.
    • Set VPN_SERVICE_PROVIDER, VPN_TYPE and your credentials in the environment section.
    • Start the container with docker compose up -d.
    • Check the container logs to confirm the VPN connection is established.
  3. 3

    Get the most out of it

    • Use the wiki's per-provider setup pages for exact settings for your VPN provider
    • Enable DNS over TLS with one or more providers for split horizon DNS
    • Use the built-in HTTP proxy on port 8888 or Shadowsocks on port 8388 from other apps
    • Connect other containers or LAN devices to route them through the VPN
    • Set UPDATER_PERIOD to keep the VPN server list current

Downloads

Strengths

  • Supports a long list of VPN providers with OpenVPN, and several with WireGuard
  • Includes a firewall kill switch that only allows traffic through the VPN
  • Small Docker image with multiple architectures supported

Trade-offs

  • Requires Docker and some networking knowledge to configure correctly
  • Setup details for each provider are in a separate wiki rather than this README
  • The latest release listed has no downloadable binaries, so Docker is the main install path

How it compares

ProjectStarsTypeLevelUpdatedBest for
gluetun (this)16kAppintermediate8 days agoPeople who want one Docker container to run traffic through a VPN for other containers
traefik65.4kAppintermediate4 days agoTeams running many microservices in Docker, Swarm, or Kubernetes
dozzle14.8kAppbeginner4 days agoDevelopers who want to watch container logs while debugging
v2ray-core46.9kOtheradvanced2 months agoDevelopers who want to read the source of a Go proxy platform
gost18.3kCLIintermediate2 months agoDevelopers who want a single binary to run a local or remote SOCKS5 or HTTP proxy
transfer.sh15.9kAppintermediate5 days agoDevelopers who want to share files from a terminal without a web browser

Stats synced from GitHub. The assessment above was drafted with AI from the project's README on 2026-10-29 and may miss recent changes — check the README before relying on a command. MIT licence: free to use, modify and distribute, including commercially, as long as you keep the copyright notice.