tun2socks Config Generator
Paste a SOCKS5 proxy string and download a tun2socks Windows launch script using the documented Wintun CLI flags.
Use the tun2socks Config Generator
tun2socks .bat Generator
Format: IP:PORT:USER:PASS or IP:PORT (no auth)
You need tun2socks.exe in the same folder. Download it from the official GitHub releases page. Run the .bat as Administrator.
Paste your proxy string on the left and click Generate.
Summary
tun2socks creates a virtual TUN adapter that can carry traffic through a SOCKS5 proxy. This tool converts IP:PORT:USER:PASS into the xjasonlyu/tun2socks v2 Windows launch form: --device wintun --proxy socks5://credentials@host:port. The generated file starts tun2socks; Windows interface addressing, DNS, routes, and a proxy-server route exception still depend on the local network and must be configured separately.
How it works
- Paste your proxy string in IP:PORT:USER:PASS format (or just IP:PORT if the proxy has no authentication).
- The tool parses the four fields, validates the host and port, and builds the .bat content with the correct tun2socks flags.
- The generated command uses the documented --device wintun and --proxy socks5://... flags.
- Click "Copy" to copy the batch script to your clipboard, or "Download .bat" to save tun2socks.bat directly.
- Place it beside tun2socks.exe, then follow the upstream Windows guide to configure the Wintun address, DNS, routes, and proxy-server exception for your network.
Use cases
- Routing all Windows PC traffic through a SOCKS5 or HTTP proxy when an app has no built-in proxy settings.
- Setting up a transparent proxy on Windows for testing, privacy, or bypassing network restrictions.
- Generating a reproducible launch script so you can switch proxies without editing .bat files by hand.
- Converting a proxy list entry (IP:PORT:USER:PASS) into a working tun2socks startup file in seconds.
- Automating proxy rotation by regenerating the .bat for each new session.