---
title: "Deploy Documenso"
description: "Open-source e-signing (DocuSign alternative) with Postgres, admin on boot"
category: "Automation"
url: https://railway.com/deploy/documenso-2
---

# Deploy Documenso

Open-source e-signing (DocuSign alternative) with Postgres, admin on boot

**[Deploy Documenso on Railway](https://railway.com/template/documenso-2)**

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

- **Creator:** Agaz Self-Host
- **Category:** Automation
- **Total deploys:** 2

## Template content

### Postgres https://devicons.railway.app/i/postgresql.svg

- **Image:** ghcr.io/railwayapp-templates/postgres-ssl:18

### Documenso https://cdn.jsdelivr.net/gh/homarr-labs/dashboard-icons/png/documenso.png

- **Source:** https://github.com/aalfath/documenso-railway-template
- **Health check:** /api/health
- **Public domain:** Yes

## Documentation

# Deploy and Host Documenso on Railway

Documenso is an open-source document signing platform and an alternative to DocuSign. You upload a PDF, place signature, initials, date and text fields, and send it to recipients, who sign in the browser. Completed documents are sealed with a digital signature and come with an audit log.

## About Hosting Documenso

Hosting Documenso needs the Node.js app, a Postgres database, a signing certificate, and a way for the first user to log in. This template builds the official Documenso image (pinned by version and digest) from a GitHub repo and adds Railway's Postgres. On first boot it creates a self-signed signing certificate on a volume, runs the database migrations, and creates an admin account for the email you enter, so you can log in without setting up email first. Public sign-up is off. Uploaded and signed PDFs are stored in Postgres. Template updates arrive as Railway update notices.

## Common Use Cases

* Sending contracts, offer letters and NDAs for e-signature without a per-seat SaaS plan
* Keeping signed documents and audit logs on infrastructure you control
* Embedding signing flows in your own product through Documenso's API and webhooks

## Dependencies for Documenso Hosting

* Postgres (Railway's Postgres service, included)
* A volume for the signing certificate (included)

### Deployment Dependencies

* Documenso: https://github.com/documenso/documenso
* Documenso v2.22.0 release: https://github.com/documenso/documenso/releases/tag/v2.22.0
* Self-hosting docs: https://docs.documenso.com/docs/self-hosting
* Template repo: https://github.com/aalfath/documenso-railway-template

### Implementation Details

You enter one value: `DOCUMENSO_ADMIN_EMAIL`. The admin password is generated as `DOCUMENSO_ADMIN_PASSWORD`; read it in the Documenso service's Variables tab, then log in at your Railway domain. Changing that variable later doesn't change the account's password.

Email is optional but recommended: signing requests, invitations and password resets are sent by email. Add `NEXT_PRIVATE_SMTP_HOST`, `NEXT_PRIVATE_SMTP_PORT`, `NEXT_PRIVATE_SMTP_USERNAME`, `NEXT_PRIVATE_SMTP_PASSWORD`, `NEXT_PRIVATE_SMTP_FROM_ADDRESS` and `NEXT_PRIVATE_SMTP_FROM_NAME` to the Documenso service. Without email you can still copy signing links by hand.

The certificate is self-signed, so PDF readers show the signature as valid but from an unknown issuer. To use your own certificate, set `NEXT_PRIVATE_SIGNING_LOCAL_FILE_CONTENTS` to the base64 of your .p12 file and `NEXT_PRIVATE_SIGNING_PASSPHRASE` to its passphrase. Set `NEXT_PUBLIC_DISABLE_SIGNUP` to `false` to let others create accounts, and update `NEXT_PUBLIC_WEBAPP_URL` if you add a custom domain. Keep the encryption keys unchanged.

## Why Deploy Documenso 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 Documenso 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

- [N8N Main + Worker](https://railway.com/deploy/n8n-main-worker) — Deploy and Host N8N with Inactive worker.
- [Evolution API with n8n](https://railway.com/deploy/evolution-api-with-n8n) — Automate WhatsApp workflows with Evolution API, n8n, and Postgres.
- [Postgres Backup](https://railway.com/deploy/postgres-s3-backups) — Cron-based PostgreSQL backup to bucket storage

Open this page in a browser: https://railway.com/deploy/documenso-2
