---
title: "Deploy Gotenberg"
description: "API to convert HTML, Markdown and Office files to PDF, with basic auth"
category: "Other"
url: https://railway.com/deploy/gotenberg-2
---

# Deploy Gotenberg

API to convert HTML, Markdown and Office files to PDF, with basic auth

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

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

- **Creator:** zer0person's Projects
- **Category:** Other
- **Total deploys:** 1

## Template content

### Gotenberg

- **Image:** gotenberg/gotenberg:8
- **Start command:** `gotenberg --api-enable-basic-auth`
- **Public domain:** Yes

## Documentation

# Deploy and Host Gotenberg on Railway

[Gotenberg](https://github.com/gotenberg/gotenberg) is a stateless API for converting HTML, Markdown, URLs and Office documents to PDF, and for merging, splitting and transforming PDFs, using Chromium and LibreOffice.

## About Hosting Gotenberg

This template runs the official `gotenberg/gotenberg:8` image on port 3000, started with basic authentication enabled so the converter is not open to the internet. The username and password are generated at deploy time: find `GOTENBERG_API_BASIC_AUTH_USERNAME` and `GOTENBERG_API_BASIC_AUTH_PASSWORD` in the service's Variables tab. Send them with every request, for example `curl --user USER:PASSWORD --form url=https://example.com https://YOUR-DOMAIN/forms/chromium/convert/url -o out.pdf`. There is no web interface; the API is documented at gotenberg.dev.

## Common Use Cases

- Generate invoices and reports as PDF from HTML templates
- Convert Word, Excel and PowerPoint files to PDF
- Merge, split and watermark PDFs from your own services

## Dependencies for Gotenberg Hosting

- One service; nothing else (no volume needed, it is stateless)

### Deployment Dependencies

- [Gotenberg on GitHub](https://github.com/gotenberg/gotenberg)
- [Docker image](https://hub.docker.com/r/gotenberg/gotenberg)
- [Documentation](https://gotenberg.dev/docs/getting-started/introduction)

## Why Deploy Gotenberg on Railway?

Railway gives you a public HTTPS URL and private networking, so your other Railway services can call Gotenberg internally, with no server to maintain.


## Similar templates

- [Rocky Linux](https://railway.com/deploy/rocky-linux) — Hosted Rocky Linux 9 workspace with SSH and persistent storage. 🚀
- [Foundry Virtual Tabletop](https://railway.com/deploy/X5tR6G) — A Self-Hosted & Modern Roleplaying Platform
- [Letta Code Remote](https://railway.com/deploy/letta-code-remote) — Run a Letta Code agent 24/7. No inbound ports, just deploy.

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