Self-hosted app·Social networks and the fediverse
Nostr relay hosting in Switzerland strfry and Blossom in ALP1.
Nostr relay hosting in ALP1, Swiss Alps: strfry on a 4 vCPU NVMe VPS, Blossom media in a 1 TB S3 bucket. Pay in crypto.
- Docker
- Caddy
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/07
Short answer.
Yes. A Nostr relay runs comfortably on our Cloud VPS Standard plan: 4 vCPU, 4 GB RAM, 160 GB NVMe and 15 TB of monthly transfer for $12.99 a month, in ALP1 in the Swiss Alps, with Debian 13 and full root. If you also want to host your users' images and video through Blossom, add a 1 TB S3-compatible bucket for $7.96 and keep the media off the VPS disk. The software is the easy part. What decides whether the relay is still pleasant to run in six months is who you allow to write to it, so settle that before you open port 443: a relay that accepts events and uploads from any key on the internet fills with spam first and, sooner or later, with material you are responsible for removing.
02/07
What a relay does, and who runs one.
Nostr has a single data type, the event: a JSON object signed with a secp256k1 key using BIP-340 Schnorr signatures. A relay is a WebSocket server that accepts EVENT messages, answers REQ subscriptions with stored events matching a filter, and keeps streaming new matches until the client sends CLOSE. Relays do not need to trust each other, because the signature is what proves authorship. A user's identity is their key rather than an account on your server, so people publish to several relays at once and can drop yours without losing anything. That is where Nostr's resistance to censorship comes from, and it also means one relay in Switzerland does nothing to stop the same note being removed elsewhere.
The people who run relays fall into a few groups. Individuals run a personal relay for their own notes and their contacts'. Communities run one for a meetup, a Bitcoin circle or the regulars of a Stacker News territory, and those members often run a full node too (our Bitcoin node guide). Operators of paid relays charge admission in sats and publish the fee schedule, in millisatoshis, in their NIP-11 information document. Blossom sits beside the relay rather than inside it: a separate HTTP server that stores files ("blobs") addressed by their SHA-256 hash, with uploads authorised by a signed kind 24242 event. Clients put the Blossom URL in a note; the relay never touches the file.
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/07
Requirements and sizing.
The examples below use strfry. It is written in C++, keeps everything in an LMDB file on local disk with no external database, verifies every signature with libsecp256k1, compresses WebSocket traffic with permessage-deflate, and supports negentropy set reconciliation (NIP-77) for syncing with other relays. nostr-rs-relay (Rust, SQLite, experimental PostgreSQL) is the usual alternative; khatru, fiatjaf's Go framework for custom relays, now lives under fiatjaf.com/nostr after its GitHub repository was archived in January 2026. The sizing logic is the same for all three.
CPU is rarely what runs out first. LMDB is memory-mapped, so the Linux page cache is your query cache: while the hot part of the database fits in RAM, reads cost almost nothing, and once it does not, queries turn into random reads from disk. That is why NVMe matters more here than core count. CPU goes on signature verification for incoming events, on negentropy syncs (strfry's documentation warns they can use a lot of memory and bandwidth when two databases differ widely) and, if you enable it, on Blossom's image resizing and video transcoding. Outbound transfer is the third limit, because every accepted event is copied to every open subscription that matches it.
| Relay profile | Plan | Specs | Price/month |
|---|---|---|---|
| Personal or family relay, allowlisted keys, no media | VPS Starter | 2 vCPU, 2 GB, 80 GB NVMe, 10 TB transfer, 1 Gbps | $6.99 |
| Community relay with Blossom (our default) | VPS Standard + 1 TB bucket | 4 vCPU, 4 GB, 160 GB NVMe, 15 TB, 1 Gbps + 1 TB bucket | $12.99 + $7.96 |
| Public relay with many readers | VPS Pro / VPS Power | 6 vCPU, 8 GB, 320 GB, 20 TB / 12 vCPU, 16 GB, 640 GB, 40 TB, 2 Gbps | $22.99 / $42.99 |
| Aggregator or archive relay | Dedicated Rigi | EPYC 4244P, 32 GB, 1 TB NVMe, 10 Gbps unmetered under fair use, DDoS protection | $64.99 |
A few theoretical figures to anchor this; they are arithmetic, not measurements. 15 TB a month averages about 5.8 MB/s, or 46 Mbit/s sustained around the clock. On disk, assume 1.5 KB per stored event once strfry's indices are counted (its README notes the indices are often large); 150 GB of usable NVMe then holds roughly 100 million events. Check your own ratio with du -sh on the database directory after the first week, because a relay of long-form articles and a relay of reactions grow very differently.
Starter is enough if it is only you and a few dozen keys. We default to Standard because the extra two cores and 2 GB leave room for Blossom and a reverse proxy beside strfry without squeezing the database out of the page cache.
04/07
How to deploy it with us.
Order the VPS with Debian 13 preselected: deploy VPS Standard in ALP1. For Blossom, order the 1 TB bucket from the object storage page; you receive an S3 endpoint and access keys, not a disk to format. Point two DNS records at the VPS, for example relay.example.org and blossom.example.org.
Build strfry as its README describes. The repository also ships a debian packaging directory, a Dockerfile and a sample Compose file if you prefer those.
apt install -y git g++ make libssl-dev zlib1g-dev liblmdb-dev libflatbuffers-dev libsecp256k1-dev libzstd-dev
git clone https://github.com/hoytech/strfry && cd strfry
git submodule update --init && make setup-golpe && make -j4
install -m 755 strfry /usr/local/bin/strfryBy default strfry listens on port 7777 and only accepts connections from localhost, which is what you want behind a TLS proxy. The parts of /etc/strfry.conf to edit first (the shipped file documents every other option):
db = "/var/lib/strfry/"
relay {
bind = "127.0.0.1"
port = 7777
info {
name = "relay.example.org"
description = "Community relay. Writes restricted to members."
pubkey = "<admin pubkey, hex>"
}
auth {
serviceUrl = "wss://relay.example.org"
}
writePolicy {
plugin = "/etc/strfry/allowlist.js"
}
}serviceUrl must be set for NIP-42 AUTH to work. Run the relay under systemd with ExecStart=/usr/local/bin/strfry --config /etc/strfry.conf relay and a generous LimitNOFILE, since every WebSocket is a file descriptor. Put Caddy in front: it obtains the certificates and passes WebSocket upgrades through reverse_proxy without extra configuration.
relay.example.org {
reverse_proxy 127.0.0.1:7777
}
blossom.example.org {
request_body {
max_size 50MB
}
reverse_proxy 127.0.0.1:3000
}Allow only 22, 80 and 443 in nftables, then check that curl -H 'Accept: application/nostr+json' https://relay.example.org returns your NIP-11 document.
For media, hzrd149's blossom-server (Deno 2) listens on port 3000 and ships a Compose file; publish the port as 127.0.0.1:3000:3000 so only Caddy can reach it. The relevant part of config.yml:
publicDomain: blossom.example.org
storage:
backend: s3
s3:
endpoint: https://<endpoint issued with your bucket>
bucket: blossom
accessKey: "${S3_ACCESS_KEY}"
secretKey: "${S3_SECRET_KEY}"
tmpDir: ./data/s3-tmp
rules:
- type: "image/*"
expiration: 1 year
pubkeys: ["<member pubkey, hex>"]
upload:
requireAuth: true
requirePubkeyInRule: true
maxSize: 52428800Without it, every image served passes through the VPS and counts against its 15 TB; at a theoretical 300 KB per image that is about 50 million views a month before notes take any share.
Back up the relay with strfry's own export, never by moving LMDB onto the bucket. A daily timer running strfry export --fried | zstd -c | rclone rcat s3:relay-backups/strfry-$(date +%F).jsonl.zst produces a file that strfry import --fried restores on a fresh VPS. LMDB needs a local filesystem; an rclone mount under it is the one setup we will tell you not to try.
05/07
Cost.
| Item | Per month |
|---|---|
| VPS Standard: 4 vCPU, 4 GB, 160 GB NVMe, 15 TB transfer, 1 Gbps | $12.99 |
| 1 TB bucket: S3 bucket, traffic not metered, no request fees | $7.96 |
| Total | $20.95 |
| Optional: daily VPS backups (+20 %) | +$2.60 |
The full list is on the pricing page. Yearly billing takes roughly 25 % off the VPS, $116.99 a year instead of $155.88. Payment is crypto only (Bitcoin, Monero, Tether USDT, Ethereum, Litecoin and others), with prices and balances in US dollars, and ordering is no-KYC: an email address is enough. Top-ups earn a bonus: $250 becomes $287.50 at 15 %, which covers about 13.7 months of the $20.95 setup at monthly rates (theoretical, at today's prices). The unused paid part of a top-up is refundable within 14 days.
Two honest limits of this setup. VPS transfer is a fixed allowance per plan, not unmetered. And a VPS shares its host and a 1 Gbps port; a relay that becomes popular, or becomes a target, belongs on a Rigi or larger with unmetered 10 Gbps under fair use.
06/07
What Swiss jurisdiction changes, and what it does not.
The server is operated by Hosta AG, a Swiss société anonyme (IDE CHE-107.875.655, Käppeligasse 1, 4125 Riehen), and sits in ALP1. Data on it falls under the revised Federal Act on Data Protection, in force since 1 September 2023. Switzerland is outside the EU, but on 15 January 2024 the European Commission confirmed that it still ensures an adequate level of protection, so EU users connecting to your relay raise no transfer question. A relay processes personal data even when every note is public: IP addresses in proxy logs, authenticated pubkeys, and payment records if you charge admission. Decide how long you keep each of them.
As of 31 October 2026 the US Department of Justice lists CLOUD Act executive agreements only with the United Kingdom and Australia. That describes the treaties in place, not a promise that no foreign request can ever have effect; we act on decisions of competent Swiss authorities. The revision of the Swiss surveillance ordinance (VÜPF/OSCPT) sent to consultation on 29 January 2025 was not in force on that date either, and the Federal Council has announced a second consultation. The offshore hosting page covers the legal background in more detail.
None of this protects the content of a note. Events are signed and copied to whichever relays the author chose, and a NIP-09 deletion is a request other relays are free to ignore.
07/07
Acceptable use, and the guardrails we expect.
Spam and unlawful uploads are why public relays are hard to run anywhere, and they reach you as operator before they reach us. A DMCA notice has no direct legal effect in Switzerland. We forward complete complaints to you, and you remove the content or justify it; we act ourselves on a decision of a competent Swiss authority, or where content is manifestly unlawful, following the Swico Code of Conduct Hosting 2025. Swiss copyright law has also carried a stay-down duty since 1 April 2020 (CopA art. 39d) for services that create a particular risk of infringement, and an open, unauthenticated media upload server is a poor place to discover whether yours qualifies.
What works in practice:
- Restrict writes. strfry's write-policy plugin receives every event with its source IP and, after NIP-42 AUTH, the authenticated pubkey, and answers
accept,rejectorshadowReject. Feed it an allowlist, or run a paid relay where a payment adds the key to that list; a Lightning node for admission fees can run on the same plan family (our Lightning node guide). Advertiserestricted_writesandpayment_requiredin NIP-11 so clients know before they try. - Restrict uploads harder than notes. Keep
upload.requireAuthon, setupload.requirePubkeyInRule: trueso only listed keys can upload, and give every storage rule an expiry. - Match hashes. Blossom addresses files by SHA-256, so a blocklist of known-bad hashes is cheap to enforce at the proxy. Exact hashes miss re-encoded copies, which is one more reason not to accept uploads from strangers at all.
- Keep a reporting path open. Leave blossom-server's BUD-09 report endpoint on (it takes NIP-56 kind 1984 reports and lists them in the
/admindashboard), publish an admin pubkey in NIP-11, and remove what you are told about withstrfry delete --filter. NIP-86 offers a standard management API on relays that implement it; strfry's README does not list it.
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 strfry in Docker instead of building it?
Yes. The strfry repository includes a Dockerfile and a sample Compose file. Keep the database on a local volume on the VPS's own NVMe rather than any network or bucket mount, and publish the port on 127.0.0.1 so that only the TLS proxy reaches it.
Is traffic unmetered on the VPS?
No. Each VPS plan includes a fixed monthly transfer: 10 TB on Starter, 15 TB on Standard, 40 TB on Power. Unmetered traffic under fair use applies to dedicated servers, which is the main reason to move a busy public relay to one. The object storage buckets themselves have unlimited traffic up and down.
Can the relay database live in the S3 bucket?
No. strfry needs LMDB on a local filesystem, and a bucket is reached through the S3 API, not mounted as a disk. Use the bucket for Blossom media and for compressed strfry export backups.
Can I sync my relay with other relays?
Yes. strfry sync wss://other.relay.example uses negentropy and transfers only the events one side is missing. The expensive case is a first sync against a large relay into an empty database, so narrow it with --filter (for example your members' pubkeys) or --range, or it will take a visible bite out of the month's transfer.
Do I have to identify myself to order?
No-KYC: an email address is enough. You pay in crypto, and business customers can pay in crypto as well.
How do I reach you about a relay setup?
Open a support ticket from the client panel. We do not publish a support email address on the site.
Sources
Every fact on this page, with its source
Consulted 3 Nov 2026 unless noted.
Swiss law and authorities
- Revised Swiss Federal Act on Data Protection, in force since 1 September 2023fedlex, RS 235.1
- VÜPF/OSCPT revision (consultation of 29 January 2025) not in force, second consultation announcedadmin.ch · status as of 31 Oct 2026
- Swiss Copyright Act, art. 39d stay-down duty since 1 April 2020 (RO 2020 1003)fedlex, LDA · verified 31 Oct 2026
EU and other countries
- European Commission review of 15 January 2024 confirming Switzerland's adequacy (decision 2000/518/EC)European Commission, adequacy decisions
- CLOUD Act executive agreements listed only with the United Kingdom and Australiajustice.gov · verified 31 Oct 2026
Industry, providers and software
- NIP-86, relay management APIgithub.com
- strfry README (LMDB storage, default port 7777 on localhost, relay.auth.serviceUrl, export/import, negentropy sync, supported NIPs)github.com/hoytech/strfry
- strfry write-policy plugins (input fields, accept/reject/shadowReject)github.com
- nostr-rs-relay (Rust, SQLite, experimental PostgreSQL)github.com/scsibug/nostr-rs-relay
- khatru (Go relay framework; GitHub repository archived 24 January 2026, development continues under fiatjaf.com/nostr)github.com/fiatjaf/khatru
- Blossom specification and BUD list (kind 24242 authorisation, BUD-09 reports)github.com/hzrd149/blossom
- blossom-server (Deno 2, port 3000, S3 backend, publicURL, upload.maxSize default 2 GB, requirePubkeyInRule, /admin dashboard)github.com/hzrd149/blossom-server
- Swico Code of Conduct Hosting, updated edition announced 13 March 2025swico.ch/coc
Other references
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.
