Railway

Deploy Vendure | Open Source Shopify Alternative on Railway

Self-host Vendure: Full e-commerce backend. GraphQL APIs, Worker

Deploy Vendure | Open Source Shopify Alternative on Railway

Vendure FrontEnd & BackEnd

Just deployed

/vendure-assets

Just deployed

/var/lib/postgresql/data

Vendure logo

Deploy and Host Vendure

Self-host Vendure — the open-source headless commerce framework built on TypeScript, Node.js, NestJS, and GraphQL. It exposes two GraphQL APIs (Shop API and Admin API) and a built-in React Admin UI, giving you a full e-commerce backend you own and control completely.

This Railway template deploys Vendure end-to-end with three pre-wired services: Vendure Server (API + Admin UI), Vendure Worker (background jobs), and PostgreSQL (persistent storage). The server and worker both build from the official one-click-deploy repository with all database credentials injected automatically. A volume is attached at /vendure-assets for uploaded product images.

Vendure Railway architecture

Getting Started with Vendure on Railway

Once your deployment turns green, navigate to your Railway-generated domain at /admin to open the Vendure Admin UI. Log in with the superadmin credentials you set via the SUPERADMIN_USERNAME and SUPERADMIN_PASSWORD environment variables. From the Admin UI you can manage your product catalogue, configure channels, set up payment methods, and create collections. To start building a custom storefront, point your frontend at the Shop API at /shop-api — it accepts GraphQL POST requests with your queries and mutations.

Vendure dashboard screenshot

About Hosting Vendure

Vendure is a developer-first headless commerce framework designed for teams that need full control over their commerce logic without inheriting a monolithic platform's constraints.

Key features:

  • Dual GraphQL APIs: Shop API for storefronts, Admin API for management
  • Built-in React Admin UI served at /admin
  • Plugin architecture — extend or override any part of the commerce logic
  • Background job queue via a dedicated Worker process (search indexing, emails, webhooks)
  • TypeScript throughout — full type safety from DB to API
  • Supports custom fields, custom entities, and custom resolvers without forking core

The server and worker run as separate Railway services sharing the same Postgres database and codebase. The worker handles async workloads so the server stays responsive under load.

Why Deploy Vendure on Railway

Deploy Vendure on Railway without touching Docker configs, volume mounts, or service discovery.

  • Postgres provisioned and credentials injected automatically
  • Persistent volume for product assets, no S3 setup needed to start
  • Private networking between server, worker, and database out of the box
  • One-click redeploys from your forked GitHub repo
  • Managed TLS and Railway-generated domain on the server

Common Use Cases

  • Multi-channel retail: Run separate storefronts (web, mobile, B2B) from a single Vendure instance using Channels
  • B2B commerce: Model custom pricing tiers, bulk ordering, and approval workflows via the plugin system
  • Headless Shopify migration: Replace Shopify's storefront with a custom frontend powered by Vendure's Shop API
  • Marketplace backend: Manage multiple vendors with separate inventories under one Admin API

Dependencies for Vendure

  • Vendure Server — GitHub: https://github.com/vendurehq/one-click-deploy, Node.js 20, port 8080
  • Vendure Worker — same repo, same image, different start command (node ./dist/index-worker.js)
  • PostgreSQLghcr.io/railwayapp-templates/postgres-ssl:18

Environment Variables Reference

VariableDescriptionRequired
SUPERADMIN_USERNAMEAdmin UI login usernameYes
SUPERADMIN_PASSWORDAdmin UI login password — generate a strong valueYes
COOKIE_SECRETSecret used to sign session cookiesYes
APP_ENVSet to production for live deploymentsYes
ASSET_UPLOAD_DIRVolume mount path for uploaded imagesYes
RUN_JOB_QUEUE_FROM_SERVERSet false to delegate jobs to the Worker serviceYes

Deployment Dependencies

Minimum Hardware Requirements for Vendure

ResourceMinimumRecommended
RAM (server)512 MB1 GB
RAM (worker)512 MB512 MB
CPU1 vCPU1 vCPU per process
Storage1 GB5 GB+ (scales with assets)
Node.js2020

Note: Vendure is single-threaded (Node.js). Adding more CPUs to a single instance has no effect — scale horizontally by running multiple server replicas instead.

Self-Hosting Vendure

Clone the one-click-deploy repo and configure a local .env:

git clone https://github.com/vendurehq/one-click-deploy.git
cd one-click-deploy
cp .env.example .env
# Edit .env with your DB credentials, SUPERADMIN_PASSWORD, COOKIE_SECRET
npm install
npm run build
npm run start:server   # in one terminal
npm run start:worker   # in another

For Docker Compose with Postgres:

services:
  postgres:
    image: postgres:16
    environment:
      POSTGRES_DB: vendure
      POSTGRES_USER: vendure
      POSTGRES_PASSWORD: secret
  server:
    build: .
    command: node ./dist/index.js
    ports: ["8080:8080"]
    environment:
      DB_HOST: postgres
      DB_PORT: 5432
      DB_NAME: vendure
      DB_USERNAME: vendure
      DB_PASSWORD: secret
      APP_ENV: production
    depends_on: [postgres]
  worker:
    build: .
    command: node ./dist/index-worker.js
    environment:
      DB_HOST: postgres
      DB_PORT: 5432
      DB_NAME: vendure
      DB_USERNAME: vendure
      DB_PASSWORD: secret
      APP_ENV: production
    depends_on: [postgres]

Is Vendure Free?

Vendure Core is MIT-licensed and free forever. The full framework, Admin UI, and plugin system are open source with no feature limits. On Railway, you pay only for infrastructure — typically under $10/month for a small store (server + worker + Postgres).

For mid-size companies, agencies, and enterprises, Vendure offers a commercial plan at 8,000 EUR/year per project, which includes priority support and enterprise features. There is no public SaaS cloud offering — Vendure is self-hosted only.

Vendure vs Medusa vs Saleor

FeatureVendureMedusaSaleor
LanguageTypeScriptJavaScript/TypeScriptPython
APIGraphQL onlyREST + GraphQLGraphQL only
Admin UIBuilt-inBuilt-inBuilt-in
Open sourceMITMITBSD
Self-hostableYesYesYes
Background jobsDedicated WorkerBuilt-inCelery workers
Best forTypeScript teams, B2BFast prototypingEnterprise Python shops

Vendure is the strongest choice for teams already invested in TypeScript who want full type safety from the database layer to the storefront.

FAQ

What is Vendure? Vendure is an open-source headless e-commerce framework built with TypeScript, NestJS, and GraphQL. It provides a Shop API for storefronts and an Admin API for management, plus a built-in React Admin UI.

What does this Railway template deploy? Three services: Vendure Server (GraphQL APIs + Admin UI at /admin), Vendure Worker (background job processing), and PostgreSQL. A persistent volume stores uploaded product images. The DB is pre-loaded with 54 sample products on first boot.

Why is a Worker service included? Vendure separates API handling from async workloads. The Worker processes jobs like search index updates, email sending, and webhook delivery. Keeping it separate means slow background tasks don't block your API.

Does Vendure support GraphQL subscriptions? Not natively out of the box — Vendure's APIs are query/mutation only. Subscriptions can be added via a custom plugin.

Can I use this in production? Yes. Set a strong SUPERADMIN_PASSWORD, replace the COOKIE_SECRET with a stable secret, connect a custom domain, and configure email settings in the EmailPlugin. The sample data can be removed via the Admin UI before go-live.

Can I add a storefront to this template? The template is backend-only. You can build any storefront — Next.js, Nuxt, SvelteKit, or a mobile app — and point it at the Shop API at /shop-api. Vendure's demo storefront is a good starting point.

What database does Vendure use? This template uses PostgreSQL. Vendure also supports MySQL and SQLite (development only).


Template Content

More templates in this category

View Template
Strapi
A popular self-hosted CMS

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

Noor Adn
View Template
Directus (docker/websocket/extensions) + PostGIS (docker/TCP) + S3/Local
Directus (Docker) + PostGIS (Docker/TCP) + S3

Protemplate