Sep 03, 2025
This tutorial will walk you through setting up Stormkit to work completely locally using Cloudflare Tunnel, allowing you to serve your application with HTTPS through your own domain while running everything on your local machine.
This setup allows you to:
Run the following command to install Stormkit with a single command.
curl -sSL https://www.stormkit.io/install.sh | sh
Alternatively, copy the contents of this docker-compose.yaml file and create an .env file similar to this example. Make sure both live in the same directory.
Add the following environment variables to the .env file:
# Disable HTTPS in Stormkit as it is going to be handled by Cloudflare
STORMKIT_HTTPS=off
# Optional: Set custom HTTP port (default is 8888)
STORMKIT_HTTP_PORT=80
# Set your domain: must be a top-level domain as Cloudflare supports automatic certificate
# generation for top and first level domains (example.com and *.example.com). Alternatively,
# you can purchase their Advanced Certificate Manager for more complex cases.
STORMKIT_DOMAIN=my-top-level-domain.com
Restart the containers so that environment variables take effect:
docker compose down hosting workerserver && docker compose up -d hosting workerserver

Follow the instructions on the screen to:
You should see an output like this:

Then, click next to configure your hostname.
In the Public Hostnames section of your tunnel:
* (for wildcard support)HTTPlocalhost:80 (match your STORMKIT_HTTP_PORT)STORMKIT_HTTP_PORTHTTP, not HTTPS

The DNS records are created automatically when you set up the public hostname. You should see:
A or AAAA record for your domain pointing to Cloudflare's tunnelYou should be able to visit https://stormkit.your-top-level-domain.com and access the Stormkit Dashboard.
Port Mismatch
STORMKIT_HTTP_PORT matches the port in your Cloudflare tunnel configurationSSL Errors
STORMKIT_HTTPS=off is setSubdomain Not Working
* for the subdomain in tunnel configurationTunnel Not Connecting
cloudflared service is runningThis setup provides a production-like development environment while keeping everything local and under your control!