Railway

Deploy WriteFreely — Self-Hosted Federated Blog

Self-host WriteFreely — minimalist blogging on the fediverse

Deploy WriteFreely — Self-Hosted Federated Blog

Just deployed

/data

Deploy and Host WriteFreely on Railway

WriteFreely is a clean, minimalist, open-source blogging platform — the engine behind Write.as — built for writers who want a distraction-free space to publish, with no ads, no tracking, and no algorithm. Its standout feature is native ActivityPub federation: your blog is part of the fediverse, so people on Mastodon and other platforms can follow it directly. This template deploys WriteFreely with SQLite on a persistent volume and federation enabled, so you own your writing space and publish in minutes.


What This Template Deploys

ServicePurpose
WriteFreelyThe blogging platform, editor, and ActivityPub server (Go)

A single lightweight service — no separate database. WriteFreely uses SQLite stored on a persistent volume at /data, which also holds its configuration, so your posts and settings survive redeploys and backups are a single file.


About Hosting

WriteFreely is simple to run, and one behavior is worth understanding to configure it correctly — this template handles it.

Federation is the differentiator — your blog joins the fediverse. With WRITEFREELY_FEDERATION=true (on by default), your blog is discoverable across the fediverse: Mastodon users and others can follow @blogname@your-domain and get your posts in their feed. This is what sets WriteFreely apart from Ghost or WordPress — you're not just publishing a site, you're publishing into a decentralized social network, reaching readers where they already are.

Environment variables configure the first boot only. This is the key thing to know: WriteFreely's environment variables are used to build its config.ini on the first start. Once that file exists on the volume, the env vars are ignored — later changes to them have no effect. So set your admin user, site name, and federation options correctly at first deploy; to change them afterward, edit config.ini on the volume directly. Getting this right upfront avoids the "I changed the variable but nothing happened" confusion.

SQLite on the volume — simple and durable. WriteFreely uses SQLite by default, the recommended choice for personal and small-to-medium blogs: no separate database service, and backups are a single file on the /data volume. Posts, users, and config all live there and survive redeploys. (MySQL is supported via a custom config.ini if you later need it.)

Set your admin account and site name. WRITEFREELY_ADMIN_USER and WRITEFREELY_ADMIN_PASSWORD create your administrator (who is also the editor on single-user instances), and WRITEFREELY_SITE_NAME sets your blog's title. After deploy, visit /login and sign in with those credentials to start writing.

Single-user or a community. Run it as a personal single-user blog, or open it up: WRITEFREELY_SINGLE_USER=false with registration or invites lets you host a small community of writers on one instance, each with their own blog and fediverse handle.

Typical cost: ~$5/month on Railway — WriteFreely is remarkably light. It's AGPL-licensed and free, with automatic HTTPS through Railway's edge.


How It Compares

WriteFreely (self-hosted)MediumGhostWordPress
FocusMinimalist writingPublishing platformPublishing + newsletterEverything
Federation (fediverse)Native ActivityPubNoPartialPlugin
Ads / trackingNoneSomeNoneVaries
FootprintVery lightN/AModerateHeavier
Data ownershipFull — your infraVendorSelf or vendorFull
Self-hostableYesNoYesYes

Medium owns your audience and shows its own prompts. Ghost is excellent but heavier and newsletter-focused. WordPress does everything but is large and plugin-dependent. WriteFreely's edge is doing one thing beautifully — clean, fast, distraction-free writing — with native fediverse federation so your blog reaches Mastodon and beyond, self-hosted at flat cost with your words on infrastructure you own.


Deploy in Under 5 Minutes

  1. Click Deploy on Railway — WriteFreely builds with a volume for data and config (~2 minutes)
  2. Set WRITEFREELY_ADMIN_USER, WRITEFREELY_ADMIN_PASSWORD, and WRITEFREELY_SITE_NAME before first boot
  3. Confirm federation and single-user settings are how you want them (they lock in at first boot)
  4. Open your Railway domain, then visit /login and sign in with your admin credentials
  5. Write your first post and publish — it's live and discoverable on the fediverse

To change settings later, edit config.ini on the volume, since env vars only apply on first boot.


Common Use Cases

  • Personal blog — a clean, ad-free space to write, owned entirely by you
  • Fediverse-native publishing — reach Mastodon and the wider fediverse directly from your blog
  • Small writing community — host multiple writers on one instance, each with their own blog
  • Privacy-first publishing — no ads, no tracking, no algorithm between you and your readers

Configuration

VariableRequiredDescription
WRITEFREELY_ADMIN_USERRequiredAdministrator username (also editor on single-user instances)
WRITEFREELY_ADMIN_PASSWORDRequiredAdministrator password — set a strong value
WRITEFREELY_SITE_NAMERecommendedYour blog's title, also used in federation
WRITEFREELY_FEDERATIONPre-settrue — ActivityPub federation on by default
WRITEFREELY_SINGLE_USEROptionalfalse to run a multi-writer community instance
Storage volumePre-setPersistent volume at /data for the SQLite database and config

Env vars apply on first boot only. They build config.ini on first start and are then ignored — set your admin, site name, and federation options correctly at deploy, and edit config.ini on the volume to change them later.

Your data is one file on the volume. SQLite and config live at /data, so posts and settings persist across redeploys and backups are a single file. Set a strong admin password.


Dependencies for WriteFreely Hosting

  • Railway account — ~$5/month for the lightweight service
  • A persistent Railway volume at /data for the database and config (included)
  • Nothing else for SQLite mode — no separate database service required
  • Optional: a MySQL service and custom config.ini for larger multi-user instances

Deployment Dependencies

Implementation Details

The template runs WriteFreely, a lightweight Go application, as a single service using SQLite stored on a persistent volume at /data, which also holds the generated config.ini. On first boot, the WRITEFREELY_* environment variables are used to construct that configuration file — admin credentials, site name, federation, single-user mode, registration, and invites — after which the file persists on the volume and the environment variables are no longer consulted; subsequent changes must be made by editing config.ini directly.

ActivityPub federation is enabled by default (WRITEFREELY_FEDERATION=true), so blogs are discoverable across the fediverse and followable from Mastodon and other platforms at @blogname@your-domain. Railway provides the public domain and automatic HTTPS at its edge. WriteFreely can run as a single-user personal blog or, with single-user mode disabled and registration or invites enabled, as a small multi-writer community, each writer with their own blog and fediverse handle.

SQLite is the default and recommended database for personal and small-to-medium instances, needing no separate service and making backups a single file; MySQL is supported through a custom config.ini for larger deployments. All posts, users, and configuration on the volume are the components to back up.


Frequently Asked Questions

How does federation work? With federation enabled by default, your blog joins the fediverse — Mastodon users and others can follow @blogname@your-domain and see your posts in their feed. It's what makes WriteFreely more than a standalone blog.

Why didn't changing an environment variable do anything? WriteFreely's env vars only build config.ini on the first boot; after that they're ignored. To change settings later, edit config.ini on the volume directly. Set things correctly at first deploy.

Which database does it use? SQLite by default, stored on the /data volume — no separate database service, and backups are a single file. MySQL is supported via a custom config.ini if you need it for a larger instance.

Do my posts persist? Yes — the SQLite database and configuration live on the persistent volume, so your posts, users, and settings survive redeploys. Back up the volume to preserve everything.

How do I log in? After deploy, visit /login and sign in with the WRITEFREELY_ADMIN_USER and WRITEFREELY_ADMIN_PASSWORD you set. On single-user instances, the admin is also the editor.


Why Deploy WriteFreely on Railway?

Railway is a singular platform to deploy your infrastructure stack. Railway will host your infrastructure so you don't have to deal with configuration, while allowing you to vertically and horizontally scale it.

By deploying WriteFreely on Railway you get a clean, federated blog with the setup handled — SQLite on a persistent volume, federation enabled, the admin account configured, and automatic HTTPS. A minimalist, ad-free writing space that reaches the fediverse, self-hosted on infrastructure you own.


Template Content

More templates in this category

View Template
Pixelfed
Explore + Share beautiful photos and videos on the Fediverse

Evan Boehs
29
View Template
NodeBB
Node.js based forum software built for the modern web

Six
65
View Template
WordPress + MySQL
Zero Config | One click | WordPress | Docker | MySQL

YAV.AI
1.4K