---
title: "Deploy WAHA Secure with Webhook"
description: "Secure WAHA for Railway with API auth, storage, and webhooks"
category: "Bots"
url: https://railway.com/deploy/waha-secure-with-webhook
---

# Deploy WAHA Secure with Webhook

Secure WAHA for Railway with API auth, storage, and webhooks

**[Deploy WAHA Secure with Webhook on Railway](https://railway.com/template/waha-secure-with-webhook)**

- **Creator:** Omry atia's Projects
- **Category:** Bots
- **Total deploys:** 43

## Template content

### WAHA Secure with Webhook

- **Image:** devlikeapro/waha:latest
- **Public domain:** Yes

## Documentation

# Deploy and Host WAHA Secure with Webhook on Railway

WAHA Secure with Webhook is a Railway-ready setup for WAHA, a self-hosted WhatsApp HTTP API. It combines API-key protection, protected dashboard and Swagger access, persistent storage for sessions and media, and webhook delivery for incoming events so your app can process WhatsApp activity in real time.

## About Hosting WAHA Secure with Webhook

Hosting WAHA Secure with Webhook on Railway means deploying WAHA as a containerized service with environment-based configuration, secure credentials, and a persistent volume. WAHA sessions represent connected WhatsApp accounts, so storage matters if you want sessions and local media to survive restarts or redeploys. WAHA can send events such as message to your backend through webhooks, which makes it easier to build bots, alerts, and workflow automations without polling. Railway templates package that setup into a reusable deployment, while Railway volumes provide the persistence WAHA needs for session and media data.

## Common Use Cases

- Build WhatsApp bots that receive incoming messages via webhook and reply through WAHA’s HTTP API.
- Forward WhatsApp events into CRMs, internal backends, or automation workflows in near real time.
- Run a self-hosted WhatsApp integration with persistent sessions, controlled API access, and local media storage.

## Dependencies for WAHA Secure with Webhook Hosting

- A Railway volume mounted to the WAHA service so session state and local media persist across redeploys.
- A backend or webhook receiver endpoint that can accept WAHA event deliveries, such as message events.

### Deployment Dependencies

https://waha.devlike.pro/docs/how-to/config/?utm_source=chatgpt.com

https://waha.devlike.pro/docs/how-to/security/?utm_source=chatgpt.com

### Implementation Details
** See this Guide When APP in UP **

https://waha.devlike.pro/blog/waha-on-docker/waha-dashboard-key_hu_46911022f802c524.webp

# Core security
WAHA_API_KEY=${{ secret(32) }}

# Public/private URLs
WAHA_BASE_URL=http://waha:3000
WAHA_PUBLIC_URL=${{RAILWAY_PUBLIC_DOMAIN}}

# Persistent local storage
WAHA_LOCAL_STORE_BASE_DIR=/data/.sessions
WHATSAPP_FILES_FOLDER=/data/.media

# Dashboard auth
WAHA_DASHBOARD_ENABLED=True
WAHA_DASHBOARD_USERNAME=${{ secret(8, 'BCDFGHJKLMNPQRSTVWXYZ+/') }}
WAHA_DASHBOARD_PASSWORD=${{ secret(16, 'BCDFGHJKLMNPQRSTVWXYZ013579+/') }}

# Swagger auth
WHATSAPP_SWAGGER_ENABLED=True
WHATSAPP_SWAGGER_USERNAME=${{ secret(8, 'BCDFGHJKLMNPQRSTVWXYZ+/') }}
WHATSAPP_SWAGGER_PASSWORD=${{ secret(16, 'BCDFGHJKLMNPQRSTVWXYZ013579+/') }}

# WhatsApp + webhooks
WHATSAPP_DEFAULT_ENGINE=WEBJS
WHATSAPP_HOOK_URL=http://backend:8080/webhook
WHATSAPP_HOOK_EVENTS=message

## Why Deploy WAHA Secure with Webhook 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 WAHA Secure with Webhook 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

- [Telegram JavaScript Bot](https://railway.com/deploy/5lRkWa) — A template for Telegram bot in JavaScript using grammY
- [Cobalt Tools [Updated Aug ’26]](https://railway.com/deploy/cobalt) — Cobalt Tools [Aug ’26] (Media Downloader, Converter & Automation) Self Host
- [Telegram Gateway](https://railway.com/deploy/railway-telegram-gateway) — Multi-bot Telegram webhook gateway with WebSocket event streaming

Open this page in a browser: https://railway.com/deploy/waha-secure-with-webhook
