A basic record of local n8n deployment.
Steps
Docker
docker-compose.yml
version: "3.9"
volumes:
n8n_storage:
services:
n8n:
image: n8nio/n8n:latest
restart: always
ports:
- "127.0.0.1:5678:5678"
volumes:
- n8n_storage:/home/node/.n8n
environment:
- WEBHOOK_URL=https://<your-ngrok-domain>.ngrok-free.app # External webhook URL
Usage
- Expose local port 5678 to the internet via ngrok:
ngrok http http://localhost:5678
Copy the generated ngrok public URL (e.g.,
https://xxxx-xxx-xxx.ngrok-free.app).Edit the
docker-compose.ymlfile and replace<your-ngrok-domain>inWEBHOOK_URLwith your actual ngrok URL.Start the n8n service using Docker Compose:
docker compose up -d
Sign up / Sign in to n8n

User account data will be persisted in the Docker volume (n8n_storage), so your credentials and workflows will be retained across container restarts.

Then you can create your own workflow!