Railway

Deploy Wiki.js | Open-Source Confluence Alternative

Self-Host Wiki.js. Modern documentation, markdown editing & more

Deploy Wiki.js | Open-Source Confluence Alternative

/var/lib/postgresql/data

Just deployed

Wiki.js logo

Deploy and Host Wiki.js on Railway

Wiki.js is a powerful open-source wiki platform built on Node.js, offering a modern interface with Markdown editing, visual editing, and full-text search. Deploy Wiki.js on Railway to self-host your own knowledge base with full data ownership, Git-backed content, and rich authentication integrations — no DevOps overhead required.

This Railway template pre-configures Wiki.js with a managed PostgreSQL database, automatic HTTPS via a public domain, and production-ready environment variables. Self-host Wiki.js on Railway and run a complete wiki platform with two services: the Wiki.js application server and a PostgreSQL 18 database.

Getting Started with Wiki.js on Railway

After deployment completes, visit your public Railway URL to access the Wiki.js setup wizard. The wizard walks you through confirming database connectivity, creating your administrator account with email and password, and setting the site URL. Once setup finishes, you land on the Wiki.js dashboard where you can create your first page using Markdown or the visual editor. Navigate to Administration > Modules to enable search engines, authentication providers (Google, GitHub, LDAP, SAML), and storage backends including Git sync. Invite team members through Administration > Users and start building your knowledge base.

Wiki.js dashboard screenshot

About Hosting Wiki.js

Wiki.js is an open-source documentation and wiki platform licensed under AGPL-3.0 with over 28,000 GitHub stars. It stores all content in a PostgreSQL database with optional Git synchronization, making it ideal for teams that want version-controlled documentation.

Key features of self-hosted Wiki.js include:

  • Multiple editors — Markdown, visual WYSIWYG, and raw HTML editing modes
  • Git sync — bidirectional synchronization with GitHub, GitLab, Bitbucket, or any Git remote
  • Authentication — built-in local auth plus 20+ providers (OAuth2, SAML, LDAP, OpenID Connect)
  • Full-text search — built-in search engine with support for Elasticsearch and Algolia
  • Multilingual — content available in 40+ languages with per-page language tagging
  • Access control — granular page-level permissions with group-based rules
  • Media management — built-in asset manager for images, documents, and files

Why Deploy Wiki.js on Railway

Railway provides the simplest path to a production Wiki.js instance:

  • One-click PostgreSQL — managed database with automatic backups and SSL
  • Zero config HTTPS — Railway provisions TLS certificates automatically
  • Scales on demand — adjust memory and CPU from the Railway dashboard
  • Git-integrated deploys — push updates through Railway's deployment pipeline
  • Private networking — Wiki.js connects to PostgreSQL over Railway's internal network

Common Use Cases for Self-Hosted Wiki.js

  • Team knowledge base — centralize internal documentation, onboarding guides, and SOPs
  • Developer documentation — publish API docs and technical references with Markdown and code highlighting
  • Product wiki — maintain customer-facing help centers and product manuals
  • Personal notes — run a private wiki for research, study notes, and bookmarks with Git backup

Dependencies for Wiki.js on Railway

This template deploys two services:

  • Wiki.jsghcr.io/requarks/wiki:2 — the Node.js wiki application server (port 3000)
  • PostgreSQL — Railway-managed PostgreSQL 18 with automatic SSL and volume persistence

Environment Variables Reference for Wiki.js

VariableDescriptionExample
DB_TYPEDatabase engine typepostgres
DB_HOSTPostgreSQL hostname${{Postgres.PGHOST}}
DB_PORTPostgreSQL port${{Postgres.PGPORT}}
DB_USERDatabase username${{Postgres.PGUSER}}
DB_PASSDatabase password${{Postgres.PGPASSWORD}}
DB_NAMEDatabase name${{Postgres.PGDATABASE}}
PORTWiki.js listening port3000
DB_SSLEnable SSL for database0

Deployment Dependencies

Hardware Requirements for Self-Hosting Wiki.js

ResourceMinimumRecommended
CPU1 core2 cores
RAM512 MB1 GB
Storage1 GB5 GB+ (scales with uploaded media)
RuntimeNode.js 22+Node.js 24+

Wiki.js itself uses approximately 70 MB of RAM at idle, with short bursts during page rendering and search indexing. PostgreSQL adds approximately 256 MB baseline.

Self-Hosting Wiki.js with Docker

Run Wiki.js locally with Docker Compose using PostgreSQL:

services:
  db:
    image: postgres:16-alpine
    environment:
      POSTGRES_DB: wiki
      POSTGRES_USER: wikijs
      POSTGRES_PASSWORD: wikijsrocks
    volumes:
      - db-data:/var/lib/postgresql/data

  wiki:
    image: ghcr.io/requarks/wiki:2
    depends_on:
      - db
    environment:
      DB_TYPE: postgres
      DB_HOST: db
      DB_PORT: 5432
      DB_USER: wikijs
      DB_PASS: wikijsrocks
      DB_NAME: wiki
    ports:
      - "3000:3000"

volumes:
  db-data:

Or run Wiki.js with a single Docker command:

docker run -d -p 3000:3000 \
  -e DB_TYPE=postgres \
  -e DB_HOST=your-postgres-host \
  -e DB_PORT=5432 \
  -e DB_USER=wikijs \
  -e DB_PASS=your-password \
  -e DB_NAME=wiki \
  ghcr.io/requarks/wiki:2

Is Wiki.js Free to Self-Host?

Wiki.js is fully open-source under the AGPL-3.0 license — there are no paid tiers, premium features, or enterprise licenses. All functionality is available for free. When self-hosting on Railway, your only cost is infrastructure: typically $5–$10/month for the Wiki.js container and PostgreSQL database combined, depending on usage.

Wiki.js vs Confluence vs BookStack

FeatureWiki.jsConfluenceBookStack
LicenseAGPL-3.0 (free)Proprietary (paid)MIT (free)
Markdown supportNativePlugin requiredLimited
Git syncBuilt-inNot availableNot available
Authentication20+ providersAtlassian SSOOAuth2, SAML, LDAP
SearchBuilt-in + ElasticsearchBuilt-inBuilt-in
Self-hostedYesData Center editionYes
Visual editorYesYesYes

Wiki.js is the strongest choice for teams that want Markdown-native documentation with Git synchronization and don't need Confluence's deep Atlassian ecosystem integration.

FAQ

What is Wiki.js and why should you self-host it? Wiki.js is an open-source wiki platform built on Node.js that provides Markdown editing, visual editing, Git synchronization, and 20+ authentication providers. Self-hosting gives you full data ownership, no per-user pricing, and the ability to customize authentication and storage backends.

What does this Wiki.js Railway template deploy? This template deploys two services: the Wiki.js application server (ghcr.io/requarks/wiki:2) running on port 3000, and a Railway-managed PostgreSQL 18 database with automatic SSL and persistent storage. Both services are connected via Railway's private internal network.

Why does Wiki.js on Railway need a PostgreSQL database? Wiki.js stores all page content, user accounts, permissions, and configuration in PostgreSQL. It is the recommended and best-supported database engine — support for MySQL, MariaDB, MSSQL, and SQLite will be dropped in future versions. PostgreSQL also enables Wiki.js's full-text search capabilities.

How do I enable Git sync in self-hosted Wiki.js? After completing the setup wizard, go to Administration > Storage and add a Git storage target. Configure the remote repository URL, branch, authentication credentials (SSH key or token), and sync interval. Wiki.js will push and pull page content as Markdown files bidirectionally.

Can I migrate from Confluence to Wiki.js on Railway? Yes. Wiki.js does not have a built-in Confluence importer, but you can export Confluence spaces as HTML or Markdown, then import pages through the Wiki.js API or by placing Markdown files in a Git repository that Wiki.js syncs with. Several community tools exist to automate this conversion.

How do I set up LDAP or SAML authentication in Wiki.js? Navigate to Administration > Authentication in the Wiki.js admin panel. Select your provider (LDAP, SAML, OAuth2, OpenID Connect, etc.) and fill in the connection details. Wiki.js supports over 20 authentication strategies including Google, GitHub, Azure AD, Okta, and custom OIDC providers.


Template Content

More templates in this category

View Template
Strapi
A popular self-hosted CMS

Milo
7.6K
Deploy
View Template
WordPress with Redis
Deploy WordPress with MariaDB and Redis

Noor Adn
View Template
NEW
Docmost
Self-hosted Notion alternative with real-time collaborative editing.

Tasha