3proxy - tiny free proxy server
(c) 2002-2026 by Vladimir '3APA3A' Dubrovin [email protected]
https://github.com/3proxy/3proxy/releases
Signed apt and dnf repositories are published at https://3proxy.org/repo/ in
two channels: current (master) and lts (0.9 branch).
Debian 12 and Ubuntu 22.04 or newer:
sudo curl -fsSL https://3proxy.org/repo/3proxy-release-key.asc \
-o /usr/share/keyrings/3proxy.asc
sudo tee /etc/apt/sources.list.d/3proxy.sources <<EOF
Types: deb
URIs: https://3proxy.org/repo/deb
Suites: current
Components: main
Signed-By: /usr/share/keyrings/3proxy.asc
EOF
sudo apt update && sudo apt install 3proxyAlmaLinux, RHEL, Rocky and CentOS Stream 8, 9 and 10:
sudo tee /etc/yum.repos.d/3proxy.repo <<EOF
[3proxy]
name=3proxy
baseurl=https://3proxy.org/repo/rpm/current/el\$releasever/\$basearch/
enabled=1
gpgcheck=1
repo_gpgcheck=1
gpgkey=https://3proxy.org/repo/3proxy-release-key.asc
EOF
sudo dnf install 3proxyBoth the packages and the repository metadata are signed. See
https://3proxy.org/repo/ for the lts channel and for release key details.
https://hub.docker.com/r/3proxy/3proxy https://github.com/3proxy/3proxy/pkgs/container/3proxy
https://github.com/z3APA3A/3proxy-archive
Documentation (man pages and HTML) available with download, on https://3proxy.org/ and in github wiki https://github.com/3proxy/3proxy/wiki
3 docker configurations are provided, default (full) also tagged as :latest, :busybox and :minimal, all refer to newest stable version. Except busybox, images are distroless and contain only binaries, you can not sh inside the container. :busybox contains busybox shell. Images are based on current (master) branch.
Images marked as LTS (:lts, :lts-busybox, :lts-minimal) are built from LTS branch (0.9.9.x)
:latest):Full installation requires to mount /etc/3proxy/3proxy.cfg files.
For docker, config can be provided via docker config
echo "log
nserver 8.8.8.8
nscache 65536
proxy -p3129" | docker config create 3proxy
docker run --read-only -p 3129:3129 --config source=3proxy,target=/etc/3proxy/3proxy.cfg --name 3proxy.full docker.io/3proxy/3proxy podman does not support config as above.
Mounts may be used as config alternative. podman used in example below can be replaced with docker:
echo "log
nserver 8.8.8.8
nscache 65536
proxy -p3129" >/path/to/local/config/directory/3proxy.cfg
podman run --read-only -p 3129:3129 -v /path/to/local/config/directory/3proxy.cfg:/etc/3proxy/3proxy.cfg --name 3proxy.full 3proxy.full use log without pathname in config to log to stdout.
plugins are located in /usr/local/3proxy/libexec (/libexec for chroot config) and since 0.9.6 symlinked by /lib and /lib64 in both chroot and non-chroot configurations, so no full path is required in plugin command. Use e.g. plugin SSLPlugin.ls.so ssl_plugin. SSLPlugin is supported since 0.9.6. Some proxy types (e.g. SOCKSv5 UDPASSCOC, SOCKSv5 BIND functionality, ftp proxy) require access to ephemeral port, you may use e.g. --network host mode or -P for docker run.
since 0.9.6 images are distroless (except :busybox) it's recommended to use with read only file system, there are no benefits from chroot. For compatibility, you still can use chroot installation by mounting directory with 3proxy.cfg to /usr/local/3proxy/config.
:busybox):full with busybox added, to allow sh and few more commands like sed inside container. All libraries are in /lib, so chroot configuration can not use plugins.
:minimal image: Dockerfile for "interactive" minimal 3proxy execution, no configuration mounting is required, configuration
is accepted from stdin. Use end command to indicate the end of configuration. Use log for stdout logging.
plugin is not supported, nserver or fakeresolve are mandatory, because system resolver is not supported, no support for RADIUS and IPv6.
Run example:
docker run --read-only -i -p 3129:3129 --name 3proxy docker.io/3proxy/3proxy:minimal
or
docker start -ai 3proxy to start existing container
send this to standard input (example):
nserver 8.8.8.8
nscache 65535
log
proxy -p3129
end nserver is required for DNS resolutions.
Some proxy types (e.g. SOCKSv5 UDPASSCOC, SOCKSv5 BIND functionality, ftp proxy) require access to ephemeral port, you may use e.g. --network host mode or -P to docker run.
:minimal without version specified uses current stable version.
Install and start proxy as Windows service:
3proxy [path_to_config_file] --installConfig file should be located in the same directory or may be optionally specified.
Remove the service (should be stopped before via net stop 3proxy):
3proxy --removegit clone https://github.com/z3apa3a/3proxy
cd 3proxy
ln -s Makefile.Linux Makefile
make
sudo make install3proxy uses 2 configuration files in :
/etc/3proxy/3proxy.cfg (before-chroot) - This configuration file is executed before chroot and should not be modified./usr/local/3proxy/conf/3proxy.cfg symlinked from /etc/3proxy/conf/3proxy.cfg (after-chroot) - Main configuration file. Modify this file if required.All paths in /usr/local/3proxy/conf/3proxy.cfg are relative to chroot directory (/usr/local/3proxy). For future versions it's planned to move 3proxy chroot directory to /var.
Log files are created in /usr/local/3proxy/logs symlinked from /var/log/3proxy.
By default, socks is started on 0.0.0.0:1080 and proxy on 0.0.0.0:3128 with basic auth, no users are added by default.
Use add3proxyuser script to add users:
add3proxyuser username password [day_limit] [bandwidth]Parameters:
day_limit - traffic limit in MB per daybandwidth - bandwidth in bits per second (1048576 = 1Mbps)Or modify /etc/3proxy/conf/ files directly.
git clone https://github.com/z3apa3a/3proxy
cd 3proxy
mkdir build && cd build
cmake ..
cmake --build .
sudo cmake --install .CMake does not use chroot configuration, config file is /etc/3proxy/3proxy.cfg
git clone https://github.com/z3apa3a/3proxy
cd 3proxy
ln -s Makefile.FreeBSD Makefile
makeBinaries are in bin/ directory.
git clone https://github.com/z3apa3a/3proxy
cd 3proxy
mkdir build && cd build
cmake ..
cmake --build .
sudo cmake --install .This installs:
/usr/local/bin//etc/3proxy//usr/local/lib/3proxy/rc.d for BSD/Library/LaunchDaemons/ for MacOS# Load and start service
sudo launchctl load /Library/LaunchDaemons/org.3proxy.3proxy.plist
# Stop service
sudo launchctl stop org.3proxy.3proxy
# Start service
sudo launchctl start org.3proxy.3proxy
# Unload and disable service
sudo launchctl unload /Library/LaunchDaemons/org.3proxy.3proxy.plistUnix:
Windows:
--install as service--remove as serviceWindows 95/98/ME:
--install as service--remove as serviceCombined
No open issues yet, or sync has not completed.