Self-hosted app·Privacy and networking
OnionShare hosting on a VPS in the Swiss Alps.
OnionShare hosting on a Debian 13 VPS in the Swiss Alps: headless onionshare-cli 2.7.1 with systemd or Docker, sizing and limits.
- Tor
- Python
- Docker
ALP1·Swiss Alps
In stockRecommended for this use case
- 1 Gbps port15 TB of transfer a monthIncluded
- Debian 13preinstalled with the orderIncluded
- DDoS protection, 1 IPv4VNC console and full rootIncluded
Optional: daily backups +20% · extra IPv4 $2 · priority support $10
Pay yearly: $116.99 a year, about 25% less
- No KYC
- Crypto only
- Swiss jurisdiction
ALP1 · Swiss Alps · Our own hardware, under Swiss law, paid in crypto
- 4 vCPU, 4 GB RAM
- 160 GB NVMe local storage
- 15 TB transfer on a 1 Gbps port
- DDoS protection included
- Swiss jurisdiction, outside the EU
01/06
Short answer.
Yes, OnionShare runs well on our Cloud VPS, and the plan we would pick is VPS Standard: 4 vCPU, 4 GB RAM, 160 GB NVMe and 15 TB of monthly transfer for $12.99, deployed with Debian 13 and onionshare-cli 2.7.1, the version on PyPI since 29 October 2026. It needs no inbound port and little CPU, so disk and the transfer allowance are what you size for. The point that matters most is the threat model. OnionShare's documentation calls it private because your own computer is the web server; on a VPS, the web server is a virtual machine on hardware we operate in ALP1. The .onion address stops visitors from learning where the service runs, but whatever lands on the disk is as readable as you leave it, so files that arrive through a receive service should be encrypted to a key that is not on the server.
02/06
What OnionShare is and who maintains it.
OnionShare is a GPLv3 Python program that starts a small Flask web server and publishes it as a Tor onion service. It has four server modes. Share mode lets people download files you choose; receive mode lets them upload files or text to you; website mode serves static HTML, CSS and JavaScript, with no server-side code and no database; chat mode runs a WebSocket room that relays messages to the people in it without storing them. By default every service is protected by Tor client authentication, so a visitor needs both the address and a private key. The --public flag removes the key requirement, which is what you want for a drop address printed on a website.
The project was started by Micah Lee, and PyPI lists him, mig5 and Saptak Sengupta as maintainers of the onionshare-cli package. The command-line build has existed since 2.3 and is the only part you need on a server. Two recent releases changed things that matter there: 2.6.4 fixed a symlink traversal and a bug that let files be uploaded when file uploads were switched off, and 2.7 (16 October 2026) moved the local web server from a TCP port to a UNIX socket on Linux and added upload size limits to receive mode. Run 2.7 or later; anything older lacks both the fixes and the limits.
Our servers are in Switzerland and answer to Swiss law. We act only on orders from competent Swiss authorities, and a request from abroad has to pass through one of them first.
03/06
Requirements and sizing.
Ports are the easy part. Tor builds its circuits outbound, visitors arrive through rendezvous relays, and since 2.7 the web server listens on a UNIX socket, so nothing on the VPS has to accept a connection from the internet. A firewall that drops all inbound traffic except SSH costs OnionShare nothing.
CPU and memory needs are modest: one Python process and one Tor client, and Tor does most of its work on a single thread. Speed is set by the Tor network rather than by our 1 Gbps port, because an onion connection crosses six relays, three picked by the visitor and three by your service. As a theoretical bound, 15 TB a month averages out to about 46 Mbit/s around the clock for 30 days; you will only approach it with many downloads running in parallel for most of the month. Tor's cell framing adds a few percent on top of the file sizes.
Disk is where OnionShare surprises people. With the default "stop sharing after files have been sent", a share of several files is compressed into a single ZIP before the address goes live, so plan on roughly the size of the share again as free space. Debian 13 mounts /tmp as a RAM-backed tmpfs capped at half the memory, so set TMPDIR to a directory on disk before sharing anything larger than a gigabyte or two. Receive mode writes each upload as an ordinary file in a timestamped folder under the data directory, which means the disk fills at whatever rate strangers choose — the reason the upload limits further down are a requirement on public drops.
| Plan | vCPU / RAM | NVMe | Transfer / month | Price | Good fit for |
|---|---|---|---|---|---|
| VPS Starter | 2 / 2 GB | 80 GB | 10 TB | $6.99 | A chat room or a small static site |
| VPS Standard | 4 / 4 GB | 160 GB | 15 TB | $12.99 | A receive drop, shares of tens of GB, Docker |
| VPS Pro | 6 / 8 GB | 320 GB | 20 TB | $22.99 | Several OnionShare services on one machine |
Starter will run OnionShare, but Standard's extra RAM and disk leave room for Docker, the ZIP step and the encryption job described below. If you need more storage than a VPS offers, our dedicated servers take up to 12 TB of NVMe and carry unmetered traffic under fair use; Tor will cap the speed long before the 10 Gbps port does, so storage is the only good reason to move up.
04/06
How to deploy it with us.
Order VPS Standard with Debian 13 from the deploy link: app.switzerland-hosting.com. Payment comes from a crypto balance and the account is no-KYC: an email address is enough. The commands below assume a root shell on the new machine.
- 01
Native install with systemd
The upstream instructions say
pip3 install --user onionshare-cli. Debian 13 refuses that because its system Python is marked as externally managed (PEP 668), so install into a virtual environment owned by a dedicated user:apt update && apt install -y tor python3-venv systemctl disable --now tor # OnionShare starts its own tor process useradd --system --create-home --home-dir /srv/onionshare onionshare sudo -u onionshare python3 -m venv /srv/onionshare/venv sudo -u onionshare /srv/onionshare/venv/bin/pip install onionshare-cli==2.7.1A public submission drop with a per-upload limit:
sudo -u onionshare /srv/onionshare/venv/bin/onionshare-cli \ --receive --public --title "Submissions" \ --persistent /srv/onionshare/drop.json \ --data-dir /srv/onionshare/inbox \ --max-upload-size 500mbTwo details catch people out. On the first start OnionShare writes these flags into
drop.json, and on later starts it reads the file, so changing a setting means editing the JSON, or deleting it and accepting a new address. The same file holds the onion service's private key, and the .onion address is derived from that key: whoever holds a copy can run your address. Keep it at mode 600 and back it up somewhere other than this VPS. For a drop meant to stay up for months, add--max-upload-size-total, which turns the same figure into a ceiling for the service's whole life; the running total lives in the JSON and survives restarts.The systemd unit in the OnionShare documentation works once
ExecStartpoints at/srv/onionshare/venv/bin/onionshare-cliandUser=andGroup=are set toonionshare. The address and, for private services, the key appear injournalctl -u onionshare-cli. - 02
Docker
The OnionShare project does not publish a container image, and the two community images we looked at on Docker Hub had gone more than a year without an update, which rules them out for software that ships security fixes. Building your own is short:
FROM debian:13-slim RUN apt-get update \ && apt-get install -y --no-install-recommends tor python3-venv ca-certificates \ && rm -rf /var/lib/apt/lists/* \ && python3 -m venv /opt/onionshare \ && /opt/onionshare/bin/pip install --no-cache-dir onionshare-cli==2.7.1 \ && useradd --create-home --uid 10001 share USER share WORKDIR /home/share ENTRYPOINT ["/opt/onionshare/bin/onionshare-cli"]# compose.yaml services: onionshare: build: . restart: unless-stopped command: ["--receive", "--public", "--persistent", "/home/share/state/drop.json", "--data-dir", "/home/share/inbox", "--max-upload-size", "500mb"] volumes: - ./state:/home/share/state - ./inbox:/home/share/inboxmkdir -p state inbox && chown 10001:10001 state inbox docker compose up -d --build && docker compose logs -fThere is no
ports:section, and there should not be one. To upgrade, change the pinned version, rebuild, and the address carries over because it lives in./state. - 03
Encrypt what arrives
OnionShare stores uploads as plaintext and adds no protection against malicious files. We recommend encrypting each file to an age public key as soon as it lands and deleting the original, with the private key kept on a machine that is not this VPS:
apt install -y inotify-tools age inotifywait -m -r -e close_write --format '%w%f' /srv/onionshare/inbox | while read -r f; do case "$f" in *.age) continue ;; esac age -r age1yourrecipientkey... -o "$f.age" "$f" && rm -- "$f" doneRun it as a second systemd unit. Skip
shred: on a thin-provisioned virtual disk it guarantees nothing, and the protection comes from the plaintext existing for seconds while the key stays elsewhere. The encrypted files anddrop.jsoncan then go to S3-compatible object storage with restic.
05/06
Cost.
| Item | Per month | Notes |
|---|---|---|
| VPS Standard | $12.99 | 4 vCPU, 4 GB RAM, 160 GB NVMe, 15 TB transfer, 1 Gbps |
| Yearly billing | ≈ $9.75 | Catalogue discount of about 25 %, $116.99 a year |
| Daily backups | +$2.60 | +20 % of the plan, $15.59 in total |
| Object storage, 250 GB | $1.99 | Bucket for restic backups of the key file and encrypted inbox |
| Priority support | +$10 | Optional |
Transfer is metered on every VPS: Standard includes 15 TB a month, which an OnionShare service will rarely approach for the reasons above. Prices are in US dollars and paid in crypto (Monero, Bitcoin, USDT, Ethereum, Litecoin and others) from a prepaid balance. Top-ups run from $25 to $5,000 with a bonus of 5 % from $50, 10 % from $100, 15 % from $250 and 20 % from $500; a $100 top-up becomes a $110 balance, which covers eight months of Standard with $6.08 left over (theoretical). The unused paid part of a top-up is refundable within 14 days. The full grid is on the pricing page.
06/06
Limits and acceptable use.
Running OnionShare, and onion services generally, is allowed on our VPS, and an onion address does not change what is lawful to publish. Swiss law lets people download a work for private use, software excepted, but making it available online without the rights holder's permission is unlawful, and a public share is a way of making something available.
Public services run with limits. A receive service started with --public must set --max-upload-size, and one meant to stay up for months must add --max-upload-size-total; a public share either keeps the default stop-after-first-download or carries --auto-stop-timer. A drop that accepts unlimited uploads from anyone becomes free storage for whoever finds it first, and that usually ends badly for the person who pays for the disk.
Keep OnionShare, and anything else you run, away from pay-per-download schemes: a file locker that pays uploaders by download count, or paid access to individual shared files. Since 1 April 2020, art. 39d of the Swiss Copyright Act puts a stay-down duty on a host whose service creates a particular risk of infringement, once a work has been made available unlawfully through it and the host has been notified; rewarding uploads by downloads is the clearest example of that risk.
Complaints follow the same path as on the rest of our network. A DMCA notice has no direct legal effect in Switzerland. We forward complete complaints to the customer, who must remove the content or justify it, and we act on a decision of a competent Swiss authority, or where the content is manifestly unlawful (Swico Code of Conduct Hosting 2025).
Catalogue·Options
Every configuration, every option, every price.
Six cloud VPS plans on AMD EPYC with local NVMe. Transfer is included on every plan, from 10 TB to 100 TB a month.
| Plan | vCPU | Memory | NVMe | Transfer | Port | Price | Deploy |
|---|---|---|---|---|---|---|---|
| StarterStaging, dev | 2 | 2 GB | 80 GB | 10 TB / month | 1 Gbps | $6.99/mo | Deploy Starter |
| StandardRecommendedSmall apps | 4 | 4 GB | 160 GB | 15 TB / month | 1 Gbps | $12.99/mo | Deploy Standard |
| ProProduction | 6 | 8 GB | 320 GB | 20 TB / month | 1 Gbps | $22.99/mo | Deploy Pro |
| PowerHeavy workloads | 12 | 16 GB | 640 GB | 40 TB / month | 2 Gbps | $42.99/mo | Deploy Power |
| UltraDatabases | 16 | 32 GB | 1000 GB | 60 TB / month | 2 Gbps | $65.99/mo | Deploy Ultra |
| SummitDense hosts | 32 | 64 GB | 2000 GB | 100 TB / month | 5 Gbps | $119.99/mo | Deploy Summit |
Every plan runs on AMD EPYC with local NVMe. Yearly billing costs about 25% less.
Every plan
- AMD EPYCon every host
- Local NVMenot network storage
- DDoS protectionalways on
- 1 IPv4 addressmore at $2 each
- VNC consoleand full root access
FAQ
Questions people ask first.
Short answers about running this in ALP1. If yours is not here, open a ticket from your panel.
Can I run OnionShare in Docker?
Yes, with your own image. The project publishes none, and the community images we checked were more than a year old. The Dockerfile and compose file above pin onionshare-cli 2.7.1 on debian:13-slim, keep the persistent JSON and the inbox in host directories, and publish no ports.
Does the .onion address survive a reboot or a move to another server?
Yes, if you start the service with --persistent. A v3 onion address is derived from the private key stored in that JSON file, so copying the file to a new VPS, together with the same command line, brings the same address back. Lose the file and the address is gone for good.
Do I need to open a port for OnionShare?
No. Tor connects outbound to the relay network, and since 2.7 OnionShare's web server listens on a local UNIX socket. Drop all inbound traffic except SSH.
What can you see as the host?
On the network side, that your VPS exchanges traffic with Tor relays and how much; who visits and what they download stays inside Tor's encryption. On the disk side we operate the hypervisor, so treat anything unencrypted on the VPS as readable by whoever runs the hardware, which is why the age step exists. The server is operated by Hosta AG — société anonyme suisse, IDE CHE-107.875.655, Käppeligasse 1, 4125 Riehen, Switzerland — under the revised Federal Act on Data Protection, in force since 1 September 2023. As of 31 October 2026 the US Department of Justice lists CLOUD Act executive agreements only with the United Kingdom and Australia, none with Switzerland, and the revision of the Swiss surveillance ordinance (VÜPF) put to consultation in January 2025 is not in force; the Federal Council has announced a second consultation. More on the legal side is on our Swiss offshore hosting page.
Is OnionShare a replacement for SecureDrop?
Not for a newsroom with sources at real risk. OnionShare's own documentation positions receive mode as a lighter and less secure cousin of SecureDrop, and it does nothing about hostile uploads; open received PDFs and Office files through Dangerzone, or in Tails or a Qubes disposable VM.
Can website mode host WordPress or another dynamic site?
No. Website mode serves static files only, with a strict Content Security Policy by default that you can disable or replace with --disable_csp or --custom_csp. For a dynamic site behind an onion address, run the site under nginx and configure a HiddenServiceDir in Tor directly.
Sources
Every fact on this page, with its source
Consulted 4 Nov 2026 unless noted.
Swiss law and authorities
- Revised Federal Act on Data Protection (FADP), RS 235.1, in force since 1 September 2023fedlex.admin.ch
- Federal Council press release on the VÜPF/OSCPT revision and second consultationadmin.ch · status as of 31 Oct 2026
- Swiss Copyright Act (CopA/LDA), art. 39d, in force since 1 April 2020 (RO 2020 1003)fedlex.admin.ch · verified 31 Oct 2026
- Swiss Federal Institute of Intellectual Property, copyright on the internet (private download permitted, software excepted; making available requires permission)ige.ch
EU and other countries
- US Department of Justice, CLOUD Act resources (executive agreements with the United Kingdom and Australia only)justice.gov · verified 31 Oct 2026
Industry, providers and software
Other references
- OnionShare 2.7.1 documentation, "How OnionShare Works" (modes, client authentication, receive-mode caveats, SecureDrop comparison, static-only website mode)docs.onionshare.org
- OnionShare 2.7.1 documentation, "Advanced Usage" (CLI flags including --max-upload-size, persistent JSON files, systemd unit, data migration)docs.onionshare.org
- PyPI, onionshare-cli 2.7.1 (released 29 October 2026; GPLv3+; Python ≥ 3.10; maintainers)pypi.org
- Docker Hub, community image davidjosearaujo/onionshare (last updated more than a year ago)hub.docker.com
ALP1·Swiss Alps
Your server in the Alps, ready when you are.
Cloud VPS start at $6.99 a month and are usually set up within minutes of your order.
