Self-hosted app·Websites, APIs and internal tools
TrailBase hosting on a Swiss VPS.
TrailBase hosting in the Swiss Alps: run the single-binary SQLite backend on a 4 vCPU / 4 GB VPS for $12.99/mo, with Docker steps, sizing and backups.
- Rust
- SQLite
- 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/06
Short answer.
Yes, you can host TrailBase with us. For a production app we recommend Cloud VPS Standard: 4 vCPU, 4 GB RAM, 160 GB NVMe and 15 TB of transfer a month for $12.99, in ALP1 in the Swiss Alps. Order it with Debian 13, run the official container behind Caddy, and the whole backend is one process and one directory.
The decision that matters most is where that directory goes. TrailBase keeps the SQLite database, the token signing keys, the configuration and its own rotating backups together in the depot on the VPS disk, so a lost disk or a deleted server takes all of it at once unless copies leave the machine. Set up off-box replication before the first user signs up, and pin the image version, because the project still ships behaviour changes in minor releases.
02/06
What TrailBase is and who builds it.
TrailBase is an open-source backend for web, mobile and desktop clients, in the same family as Firebase and PocketBase. Point it at your tables and it serves type-safe REST endpoints and realtime subscriptions over them, guarded by access rules written as SQL expressions. Around that sit authentication (passwords, OAuth and OpenID Connect, one-time codes, TOTP, guest accounts), file uploads, scheduled jobs and an admin dashboard with a SQL editor. It is a single Rust executable. Data lives in SQLite; a Postgres backend exists, but the release notes still call it experimental. Custom server logic runs as WebAssembly components inside Wasmtime, and official clients cover JavaScript/TypeScript, Dart/Flutter, Rust, C#, Swift, Kotlin, Go and Python.
The code is developed in the open by the trailbaseio project on GitHub, with outside contributors credited release by release. The licence is OSL-3.0, chosen because its definition of a derivative work stops at changes to TrailBase itself, so an application built on top stays outside the copyleft. The README still carries an alpha badge and the project FAQ answers the production question with "yes and no", which we read as honest rather than alarming. It does have a practical consequence: between v0.33.23 on 28 September and v0.35.9 on 3 November 2026, v0.34.0 changed how WASM ATTACH DATABASE paths resolve and v0.35.0 changed the ids returned for ignored batch inserts. Read the changelog before every upgrade.
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.
The official image is built on Alpine 3.23, weighs 45 MB compressed on amd64 (44 MB on arm64) at v0.35.9, runs as an unprivileged trailbase user, listens on port 4000 and answers health checks at /api/healthcheck. There is no separate database server, cache or Node runtime. From the internet you need SSH, 80 and 443; port 4000 and the admin port stay on loopback.
Resource use follows your data rather than the server. SQLite reads come from the page cache, so the RAM that matters is the hot part of your database plus whatever your WASM handlers allocate. Disk holds main.db, the request log in logs.db (seven days by default) and the local backups TrailBase rotates (five by default). All writes go through a single writer, which most apps never notice and which is why TrailBase grows by moving to a bigger machine rather than by adding nodes.
| Plan | vCPU / RAM / NVMe | Transfer per month | Price per month | Where it fits |
|---|---|---|---|---|
| Cloud VPS Starter | 2 / 2 GB / 80 GB | 10 TB | $6.99 | Staging, previews, a side project |
| Cloud VPS Standard | 4 / 4 GB / 160 GB | 15 TB | $12.99 | Most production apps (our pick) |
| Cloud VPS Pro | 6 / 8 GB / 320 GB | 20 TB | $22.99 | Large databases, heavy WASM jobs |
Two theoretical checks help you choose. If each local backup is a full copy of the database (confirm this on your version), a 20 GB main.db with five backups occupies about 120 GB before logs and uploads, which is where Standard's 160 GB stops being comfortable. VPS traffic is not unmetered: 15 TB a month averages roughly 46 Mbit/s around the clock, or three billion API responses of 5 KB. JSON rarely gets near that, but file downloads can, because TrailBase serves uploads through its record API so that access rules apply, and every byte crosses the VPS even when the file sits in a bucket. When your hot data outgrows VPS memory, a dedicated server such as Rigi (EPYC 4244P, 32 GB DDR5 ECC, 1 TB NVMe Gen4, $64.99 a month) gives the page cache room; the larger VPS sizes are on the Cloud VPS page.
04/06
Deploying TrailBase with us.
- 01
1. Order and prepare the VPS
Order Cloud VPS Standard with Debian 13 from the deploy link. Sign-up is no-KYC: an email address is enough (more on our no-KYC hosting page). Install Docker Engine and the compose plugin from Docker's Debian repository, add a non-root user, and allow only SSH, HTTP and HTTPS inbound. Docker inserts published ports ahead of ufw's rules, so a host firewall will not hide a container port published on 0.0.0.0; that is why the compose file binds to 127.0.0.1.
- 02
2. Start the container
The image runs as UID 1000, so the depot must be writable by that UID:
sudo mkdir -p /srv/trailbase/traildepot sudo chown 1000:1000 /srv/trailbase/traildepot/srv/trailbase/compose.yaml:services: trailbase: image: trailbase/trailbase:0.35.9 # pin; read the changelog before bumping restart: unless-stopped command: - /app/trail - --data-dir - /app/traildepot - run - --address - 0.0.0.0:4000 # public API, published to loopback only - --admin-address - 0.0.0.0:4001 # admin API and dashboard on their own port ports: - "127.0.0.1:4000:4000" - "127.0.0.1:4001:4001" volumes: - ./traildepot:/app/traildepotcd /srv/trailbase docker compose up -d docker compose logs trailbase | grep -A2 "Created new admin user" docker compose exec trailbase /app/trail user change-password admin@localhost 'a-long-passphrase'The first start creates the depot and prints the admin login,
admin@localhostwith a random password, which the last command replaces. The bind mount hides the optional auth UI (ready-made sign-in pages) that the image ships under/app/traildepot/wasm; if you want it, rundocker compose run --rm trailbase /app/trail components add trailbase/auth_uionce. To reach the dashboard, tunnel the admin port (ssh -L 4001:127.0.0.1:4001 you@your-vps) and openhttp://localhost:4001/_/admin/, so it never faces the internet. - 03
3. TLS, reverse proxy and site_url
TrailBase can serve TLS itself from
key.pemandcert.pemintraildepot/secrets/certs/, but it does not obtain or renew certificates. Caddy does both and setsX-Forwarded-For, which TrailBase needs for its logs and IP rate limiting:api.example.com { reverse_proxy 127.0.0.1:4000 { flush_interval -1 } }flush_interval -1stops the proxy from buffering the server-sent events behind realtime subscriptions. In theserverblock oftraildepot/config.textproto, setsite_urlto"https://api.example.com": it defaults tohttp://localhost:4000, and every verification link and OAuth redirect is built from it. Turn onauth_ip_rate_limit(off by default), raiserequest_size_limit_bytes(10 MB by default) if users upload larger files, and restart. - 04
4. Email
By default TrailBase hands mail to sendmail, and nothing in the container delivers it, so verification and reset mail will not go out until you fill in the
emailblock (smtp_host,smtp_port,smtp_username,smtp_password,sender_address; STARTTLS is the default). Outbound port 25 is open on every VPS we sell, so your own mail server is allowed, but a new IP has no sending reputation and password resets are the wrong place to build one. A transactional relay on port 587 is the sober choice; our answer on port 25 has the details. - 05
5. Uploads and backups
Uploads stay on local disk inside the depot unless you configure S3. Our object storage is S3-compatible, billed by size only with no request fees, and fits TrailBase's
s3_storage_config:server { s3_storage_config { endpoint: "https://<endpoint shown in your panel>" region: "<region shown on the bucket's page>" bucket_name: "trailbase-uploads" access_key: "<access key>" secret_access_key: "<secret key>" } }The database itself stays on the VPS's NVMe; a bucket is not a block device, and SQLite on an rclone mount is a corruption report waiting to be written. TrailBase's built-in backups land in the depot, on the same disk, which protects you from a bad migration and little else. For an off-site copy, TrailBase's production guide points to Litestream, which streams
main.dbchanges into an S3-compatible bucket; add a nightly restic snapshot of the whole depot so the secrets travel too, because losing the signing keys invalidates every issued session. Our daily VPS backups (+20 %) are a third layer, and none of the three counts until you have restored from it once.
05/06
What it costs.
| Item | Per month |
|---|---|
| Cloud VPS Standard (4 vCPU, 4 GB, 160 GB NVMe, 15 TB transfer, 1 Gbps) | $12.99 |
| Daily VPS backups (+20 %) | $2.60 |
| Object storage, 250 GB bucket for uploads and replicas | $1.99 |
| Total | $17.58 |
TrailBase has no licence fee. The VPS includes 15 TB of monthly transfer at 1 Gbps and an IPv4 address; an extra IPv4 is $2 and priority support $10 a month. Yearly billing takes roughly 25 % off, about $9.75 a month for the VPS in theory; the panel shows the exact figure. We do not manage TrailBase: upgrades, configuration and restore tests are yours.
Payment is crypto only (Monero, Bitcoin, Tether (USDT), Ethereum, Litecoin and other coins), with prices and balances in US dollars. 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, and the unused paid part is refundable within 14 days. Without a wallet that is a real obstacle, and we would rather say so here than at checkout. All plans and options are on the pricing page.
06/06
Limits, acceptable use and your obligations.
Running TrailBase makes you the operator of a user database. Under the revised Swiss Federal Act on Data Protection, in force since 1 September 2023, you are the controller for what your instance stores: email addresses, password hashes, uploaded files and the client IPs in logs.db (shorten logs_retention_sec if seven days is more than you need). On 15 January 2024 the European Commission confirmed that Switzerland still ensures an adequate level of protection, so EU users' data can flow to ALP1 without additional safeguards. 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. That removes one shortcut for foreign data requests; it does not put your server beyond the law, since Swiss authorities can still order disclosure under Swiss procedure. Our offshore hosting page covers the jurisdiction.
Files your users upload are your responsibility. 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). Since 1 April 2020, CopA art. 39d adds a stay-down duty only when a work was already made available unlawfully through the same service, the provider was notified, and the service creates a particular risk of infringement; an upload-heavy app without moderation is where that last condition starts to bite.
If your app offers crypto-asset services, Swiss sanctions (Ordinance SR 946.231.176.72, art. 20(2)) have since 26 February 2026 prohibited providing them to Russian nationals, people residing in Russia and entities established there, subject to the ordinance's exceptions; screening is your job. Mail through the open port 25 is yours too, and bulk mail nobody asked for gets the address blocklisted for every service on the machine. The binding rules are in our acceptable use policy; questions go through a support ticket from the client panel.
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 self-host TrailBase without Docker?
Yes. The GitHub releases include Linux builds you can place in /usr/local/bin and run from a systemd unit, for example trail --data-dir /var/lib/trailbase run --address 127.0.0.1:4000 --admin-address 127.0.0.1:4001. On a production server we prefer downloading and checking the release archive over the curl | bash installer. Docker mainly earns its place by making version pinning and rollback a one-line change.
Is Cloud VPS Starter enough for TrailBase?
For staging, previews or a small internal tool, yes: 2 vCPU, 2 GB RAM and 80 GB NVMe for $6.99 a month. For an app with real users we prefer Standard, because the extra RAM goes to SQLite's page cache and the extra disk holds local backups without crowding the database.
Can TrailBase scale beyond one server?
Not for writes. Like the SQLite underneath, it takes one writer at a time, so you scale up: Pro, Power, then a dedicated server. Litestream replicas give eventually consistent read copies and a recovery path, and the project FAQ describes one instance per tenant as a way to shard when the data model allows it.
Can I keep TrailBase uploads in your object storage?
Yes, through s3_storage_config. A 250 GB bucket costs $1.99 a month with no request fees and unlimited bucket traffic, but downloads still pass through TrailBase and count against the VPS's monthly transfer.
What happens if I receive a DMCA notice about a user's upload?
We forward the complete complaint to you, and you remove the file or justify keeping it. The notice has no direct legal effect in Switzerland; we act on a decision of a competent Swiss authority, or where the content is manifestly unlawful.
Sources
Every fact on this page, with its source
Checked 4 Nov 2026 unless noted.
Swiss law and authorities
- fedlex.admin.chfedlex.admin.ch
- Federal Act on Copyright, CopA art. 39dFederal Act on Copyright, CopA art. 39d · verified 31 Oct 2026
- SECO press release, 25 February 2026SECO press release, 25 February 2026
EU and other countries
- European Commission, adequacy decisionsEuropean Commission, adequacy decisions
- justice.govjustice.gov · verified 31 Oct 2026
Industry, providers and software
- TrailBase repository and READMETrailBase repository and README
- TrailBase v0.35.9 release notesTrailBase v0.35.9 release notes
- TrailBase release listTrailBase release list
- Official DockerfileOfficial Dockerfile
- config.protoconfig.proto
Other references
- Docker Hub tags, trailbase/trailbaseDocker Hub tags, trailbase/trailbase
- TrailBase docs, Install & RunTrailBase docs, Install & Run
- TrailBase docs, ProductionTrailBase docs, Production
- TrailBase FAQTrailBase FAQ
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.
