Deploy Haben

German bookkeeping on your own server: e-invoices, EÜR and ELSTER.

Deploy Haben

Just deployed

/var/lib/postgresql

Just deployed

/var/lib/haben

Deploy and Host Haben on Railway

Haben logo

Haben is an open source bookkeeping app for German freelancers, sole traders and small GmbH or UG companies. It covers the whole path from invoice to tax office: e-invoices in ZUGFeRD and XRechnung, receipts, bank reconciliation, EÜR or balance sheet with E-Bilanz, VAT pre-returns and annual returns sent to ELSTER, all built with the GoBD in mind and a DATEV export for your tax adviser. Haben is AGPL-3.0 licensed with about 790 GitHub stars and is labelled Beta by its developers. The app and its documentation are in German. This template runs Haben 0.6.5 with its PostgreSQL 18 database on Railway, with generated secrets, HTTPS and private networking already set up. Lexware Office and sevDesk charge a monthly subscription, roughly €10–€30/month depending on the plan (approximate). Haben on Railway usually costs about $5–10/month for the app and database, and your books stay on your own volumes.


What This Template Deploys

ServicePurpose
habenThe Haben web app, from ghcr.io/onepush-dev/haben:0.6.5, which wraps the unmodified upstream image with a Railway start script. Public HTTPS domain, health check on /api/auth/ok, volume at /var/lib/haben for uploaded receipts, documents and app files.
haben-dbPostgreSQL 18 from ghcr.io/onepush-dev/haben-db:0.6.5, private only, with a volume at /var/lib/postgresql for your bookings, invoices and audit log.

The app reaches the database over Railway's private network. The upstream Caddy proxy and restic backup containers are not included: Railway provides HTTPS, and backups are covered below.


About Hosting Haben

Bookkeeping data is some of the most sensitive data a business has. Haben keeps invoices, bank transactions and tax filings on a server you control, without a per-month software subscription.

E-invoices built in. Create invoices with a live PDF preview and embed ZUGFeRD or XRechnung data, checked against the KoSIT validator. Credit notes, partial and recurring invoices and dunning are included.

Receipts and bank matching. Upload receipts by drag and drop, camera or email. Bank transactions come in by import or automatic fetch, and Haben suggests matches with the reason for each one.

VAT and ELSTER. Haben calculates the Umsatzsteuer-Voranmeldung from your bookings, shows where every figure comes from, and sends it via ERiC or as an XML upload to Mein ELSTER.

EÜR, balance sheet and E-Bilanz. Freelancers get the Anlage EÜR. A GmbH or UG gets balance sheet, profit and loss and E-Bilanz.

Built for the GoBD. Finalised entries are locked by a database trigger, corrections run through reversals, and an audit log records every change.

Moving from other tools. Import invoices, receipts, bookings and contacts from Lexware Office, sevDesk and others, then compare each year before you cancel the old subscription.

Access for your tax adviser. Give your Steuerberatung a read-only login or hand over a DATEV export.


Deploy Haben in Under 5 Minutes

  1. Click Deploy on Railway. No inputs are needed; all secrets are generated.
  2. Wait for both services to turn healthy, then open the haben domain. Haben sends you to /setup.
  3. Copy HABEN_SETUP_CODE from the haben service's variables and enter it on the setup page.
  4. Create the owner account with your name, email and a password of at least 12 characters.
  5. Save HABEN_ENCRYPTION_KEY in a password manager, then fill in your company details under Settings.

Important: Keep the Encryption Key Safe

HABEN_ENCRYPTION_KEY encrypts stored credentials such as your ELSTER certificate and PIN, bank logins, mail passwords and the API keys you use for imports. Database backups do not contain the key. If you lose it, those credentials cannot be decrypted after a restore and must be entered again. Store it outside Railway, and never change it once you have saved credentials.


Common Use Cases

  • Freelancers with EÜR: invoices, receipts and the Anlage EÜR in one place.
  • Kleinunternehmer: small-business VAT rules under § 19 UStG handled automatically.
  • Small GmbH or UG: double-entry bookkeeping with SKR03 or SKR04, balance sheet and E-Bilanz.
  • E-invoice compliance: send and receive ZUGFeRD and XRechnung invoices for B2B customers.
  • Leaving Lexware Office or sevDesk: import your history and check it year by year.
  • Working with a tax adviser: read-only access or DATEV export instead of shoeboxes.
  • Data sovereignty: keep financial records off third-party SaaS platforms.
  • Payroll for small teams: run payslips for minijobs and managing directors and file the Lohnsteuer-Anmeldung.

Configuration

VariableDefaultDescription
HABEN_SETUP_CODE🔐 Auto-generatedOne-time code for /setup; unused once the owner account exists
HABEN_ENCRYPTION_KEY🔐 Auto-generated32-byte key that encrypts stored credentials; back it up separately
BETTER_AUTH_SECRET🔐 Auto-generatedSigns login sessions; keep it stable
BETTER_AUTH_URLRailway domainPublic HTTPS address; passkeys are bound to it
DATABASE_URLprivate Postgres URLBuilt from the haben-db address and password
POSTGRES_PASSWORD🔐 Auto-generatedDatabase password on haben-db

Custom domain. Add the domain to the haben service and update BETTER_AUTH_URL before you register passkeys, because passkeys only work on the address they were created for.

ELSTER via ERiC. Direct submission needs an ELSTER certificate and your own Hersteller-ID, which can take one to two weeks to get. Until then, use the XML upload to Mein ELSTER.

Backups. Back up both volumes, and keep regular pg_dump copies of the database somewhere outside Railway. Back up before every update.

Updates. This template pins Haben 0.6.5, while upstream has moved on to 0.12.0. Haben is Beta and its migrations cannot be rolled back, so take a full backup and read the release notes before changing the image tag.

Language. The interface and documentation are German only.


Getting Started with Your Books

Fill in company details first. Tax number, VAT ID, tax office and chart of accounts drive invoices and returns, so set them before your first invoice.

Choose cash or accrual VAT. Pick Ist- or Soll-Versteuerung to match what your tax office approved, since it changes every VAT figure.

Connect the bank early. Importing a few months of transactions lets Haben learn your matching patterns and catch missing receipts.

Request ELSTER access now. The certificate and Hersteller-ID take time; start the process on day one.

Check before you file. Haben is Beta. Review every report and return before sending it to the tax office.

Invite your adviser. A read-only login saves sending exports back and forth.


Haben vs. Alternatives

FeatureHaben on RailwayLexware OfficesevDeskSpreadsheet and Mein ELSTER
HostingSelf-hostedHosted SaaSHosted SaaSYour own files
LicenseAGPL-3.0ProprietaryProprietaryNot applicable
ZUGFeRD and XRechnung✅✅✅❌
VAT return to ELSTER✅✅✅Typed by hand
E-Bilanz for GmbH✅Varies by planVaries by plan❌
Data on your own server✅❌❌✅
PriceAbout $5–10/month hostingRoughly €10–€30/month (approximate)Roughly €10–€30/month (approximate)Free

Lexware Office and sevDesk need no server and offer support. A spreadsheet is free but makes every filing manual. Haben gives you a full German bookkeeping workflow on infrastructure you own.


Dependencies for Haben Hosting

  • A Railway account.
  • Optional: an ELSTER certificate and Hersteller-ID for direct ERiC submission.

Deployment Dependencies

Implementation Details

The app image runs the unmodified upstream Haben image with a start script for Railway. Postgres 18 runs in its own service and is reachable only on the private network.


Frequently Asked Questions

What is Haben? An AGPL-3.0 open source bookkeeping app for German freelancers and small companies, with e-invoices and ELSTER filing.

How much does it cost to host? Usually about $5–10/month on Railway for the app, database and volumes.

Where do I find the setup code? In the haben service's variables as HABEN_SETUP_CODE, entered on the /setup page.

What happens if I lose HABEN_ENCRYPTION_KEY? Stored ELSTER, bank and API credentials cannot be decrypted and must be entered again.

Is Haben production-ready? It is labelled Beta. Back up before each update and check reports before filing.

Is the app available in English? No. The interface and documentation are in German.


Why Deploy and Host Haben 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 Haben on Railway, you get German bookkeeping, e-invoicing and ELSTER filing on your own server, with your books in volumes you control.


Template Content

More templates in this category

View Template
Rocky Linux
Hosted Rocky Linux 9 workspace with SSH and persistent storage. 🚀

codestorm
51
View Template
Foundry Virtual Tabletop
Self-hosted virtual tabletop for role-playing games (license required)

Lucas
71
View Template
NEW
Double Commander in your browser
The Double Commander file manager in the cloud, from any device

Nermin Sabanovic
0