---
title: "Deploy Pixelfed"
description: "Federated, ad-free photo sharing (Instagram alternative) with admin set up"
category: "Blogs"
url: https://railway.com/deploy/pixelfed-1
---

# Deploy Pixelfed

Federated, ad-free photo sharing (Instagram alternative) with admin set up

**[Deploy Pixelfed on Railway](https://railway.com/template/pixelfed-1)**

Machine-readable deploy manifest (JSON, validated by TemplateCI): https://railway.com/deploy/pixelfed-1/manifest.json

- **Creator:** Agaz Self-Host
- **Category:** Blogs

## Template content

### Pixelfed https://cdn.jsdelivr.net/gh/homarr-labs/dashboard-icons/png/pixelfed.png

- **Source:** https://github.com/aalfath/pixelfed-railway-template
- **Health check:** /api/v1/instance
- **Public domain:** Yes

### MySQL https://devicons.railway.app/i/mysql.svg

- **Source:** https://github.com/aalfath/pixelfed-railway-template

### Redis https://devicons.railway.app/i/redis.svg

- **Source:** https://github.com/aalfath/pixelfed-railway-template

## Documentation

# Deploy and Host Pixelfed on Railway

Pixelfed is a free, open-source photo sharing platform, an ad-free alternative to Instagram. Users post photos, albums and stories to a chronological feed. Because it speaks ActivityPub, a Pixelfed instance federates with Mastodon and the rest of the fediverse, so its users can follow and be followed across servers.

## About Hosting Pixelfed

Pixelfed is a Laravel (PHP) application. It needs a MySQL database, Redis for cache and queues, a queue worker (Horizon) that processes uploads and federation, a scheduler, and persistent disk for media and OAuth keys. This template runs the official Pixelfed v0.15.2 image with Horizon and the scheduler in the same service, MySQL 8.4 LTS and Redis 8.10, each on its own volume. All images are pinned by version and digest. On the first start it runs the migrations, creates OAuth keys and the instance actor, imports the city list, and creates your admin account. Passwords and the app key are generated for each deploy.

## Common Use Cases

* A private photo sharing space for a family, a club or a team
* A public, federated photo community that Mastodon users can follow
* A personal photo blog that you own, with no ads and no algorithmic feed

## Dependencies for Pixelfed Hosting

* MySQL 8.4 (included, on a volume)
* Redis 8.10 (included, on a volume)

### Deployment Dependencies

* Pixelfed release: https://github.com/pixelfed/pixelfed/releases/tag/v0.15.2
* Pixelfed Docker setup: https://github.com/pixelfed/pixelfed/blob/v0.15.2/DOCKER_COMPOSE_SETUP.md
* Template repo: https://github.com/aalfath/pixelfed-railway-template

### Implementation Details

**After deploy:** enter your email as `ADMIN_EMAIL`. When the Pixelfed service is up, open its domain and log in with that email and the generated `ADMIN_PASSWORD` (Pixelfed service → Variables). The admin panel is at `/i/admin/dashboard`.

**Sign-ups are closed** until you open them in Admin → Settings, or set `OPEN_REGISTRATION=true`. Mail goes to the service log until you add SMTP settings (`MAIL_MAILER=smtp`, `MAIL_HOST`, `MAIL_PORT`, `MAIL_USERNAME`, `MAIL_PASSWORD`, `MAIL_FROM_ADDRESS`). Add those before you enable email verification.

**Custom domain:** set `APP_DOMAIN` to it before your instance starts federating. The domain is part of every account's fediverse address, and changing it later breaks existing follows.

**Storage:** uploads go to the Pixelfed volume. For a large instance, set `PF_ENABLE_CLOUD=true` with the `AWS_*` settings to keep media in S3-compatible storage.

**Updates:** the services build from the template's GitHub repo. When a new Pixelfed release is pinned there, Railway shows an update notice on your project. Read the repo's CHANGELOG.md, back up the MySQL volume, then apply it. Migrations run on the next start.

## Why Deploy Pixelfed 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 Pixelfed on Railway, you are one step closer to supporting a complete full-stack application with minimal burden. Host your servers, databases, AI agents, and more on Railway.



## Similar templates

- [Pixelfed](https://railway.com/deploy/OZSdEw) — Explore + Share beautiful photos and videos on the Fediverse
- [Hexo](https://railway.com/deploy/hexo) — Hexo — fast static blog framework with admin editor and S3 media storage
- [Castopod](https://railway.com/deploy/castopod-clone) — Self-hosted podcast hosting with Fediverse support

Open this page in a browser: https://railway.com/deploy/pixelfed-1
