Deploy HedgeDoc

Real-time collaborative Markdown notes, slides and uploads

Deploy HedgeDoc

Just deployed

/hedgedoc/public/uploads

Just deployed

/var/lib/postgresql/data

Deploy and Host

Deploy on Railway

HedgeDoc feature demonstration page

HedgeDoc is a real-time, collaborative Markdown editor — the self-hosted HackMD successor. Write notes together with live cursors, preview Markdown as you type, present any note as slides, and upload images. This template ships HedgeDoc 1.12.3 pinned by digest with a PostgreSQL companion, so the deploy form has one field: the session secret.

About Hosting

One click deploys HedgeDoc with a PostgreSQL 16 companion. The first boot wires the database, derives the public URL from the live domain, and lands on the HedgeDoc landing page — register the first account in the UI and start writing. Notes default to private; per-note permissions are changeable in the UI. Railway's injected PORT is honored on every boot, and the public URL is derived from the live domain.

What gets deployed:

  • hedgedoc — HedgeDoc 1.12.3 (Node 24) with an uploads volume at /hedgedoc/public/uploads
  • postgres — PostgreSQL 16 companion with a persistent volume at /var/lib/postgresql/data
  • First account — register in the UI (local auth, no email verification); the first account is the instance admin

Why Deploy

  • Real collaboration: multiple cursors on the same note, live preview, and slide mode for presenting.
  • Zero-fuss start: no wizard — the database URL, public domain, and session secret are wired at boot.
  • Always-on by design: notes, history, and uploads persist on Railway volumes.

Common Use Cases

  • Run a shared team notebook with live collaborative editing.
  • Replace a shared docs folder with Markdown notes anyone on the team can edit and link.
  • Keep meeting minutes as collaborative notes with slide mode for presenting.
  • Host a public Markdown pad with per-note permissions.

Dependencies for HedgeDoc Hosting

  • The hedgedoc service with a volume at /hedgedoc/public/uploads and the postgres companion with a volume at /var/lib/postgresql/data, both created by the template. A custom domain is optional.

Deployment Dependencies

SettingValue
RuntimeHedgeDoc 1.12.3 (Node 24) + PostgreSQL 16
PlanHobby; two services
PortRailway's injected PORT, honored on every boot via CMD_PORT (default 8080)
PersistenceTwo Railway volumes: /hedgedoc/public/uploads (app) and /var/lib/postgresql/data (Postgres)
Healthcheck/ (unauthenticated landing page, 200 when the app is up)
VariableValueNotes
HD_SESSION_SECRET(generated)Deploy-form field; session secret for logins
POSTGRES_HOST(auto-wired)${{postgres.RAILWAY_PRIVATE_DOMAIN}} — private-network host of the companion
POSTGRES_PASSWORD(auto-wired)${{postgres.POSTGRES_PASSWORD}} — generated password of the companion
CMD_DEFAULT_PERMISSIONprivateBaked in the image; new notes are private by default (upstream default is editable)
CMD_ALLOW_EMAIL_REGISTERtrueBaked in the image; local registration open, no email verification step
CMD_IMAGE_UPLOAD_TYPEfilesystemBaked in the image; uploads stored on the volume
CMD_PORT(injected by Railway)Derived from PORT on every boot
CMD_DOMAIN(derived at boot)Re-derived from RAILWAY_PUBLIC_DOMAIN on every boot

Baked internals: CMD_DB_URL is composed at boot from POSTGRES_HOST + POSTGRES_PASSWORD (user hedgedoc, database hedgedoc, port 5432); uploads at /hedgedoc/public/uploads; CMD_SESSION_SECRET is set from HD_SESSION_SECRET.


Template Content

More templates in this category

View Template
Libredesk - Complete Setup
Complete self-hosted omnichannel customer support desk.

codestorm
2
View Template
Paperless-ngx
Paperless-ngx — document management with OCR and full-text search

INAPP
1
View Template
Instatic CMS - Postgres
Design, build and manage powerful static sites from state-of-the-art CMS

Instatic
169