Self-Host OpenClaw on Render
Render provides the fastest path to a hosted OpenClaw instance. Using Render Blueprints, you can deploy directly from the repository with a single click. Render handles the Docker build, persistent storage, TLS certificates, and health monitoring. This guide covers everything from the initial deploy through production hardening.
Quick Path
For developers who have used Render before:
- Fork the OpenClaw repository on GitHub
- Click "New Blueprint Instance" in your Render dashboard
- Connect your fork and select the
render.yamlfile - Set the
ANTHROPIC_API_KEYenvironment variable - Deploy — Render auto-generates the gateway token
- Access your instance at
https://your-service.onrender.com/
Prerequisites
- A Render account (free to create)
- A GitHub or GitLab account with a fork of the OpenClaw repository
- An API key from your preferred LLM provider (Anthropic, OpenAI, or OpenRouter)
How the Blueprint Works
The OpenClaw repository includes a render.yaml file that defines the entire deployment:
When you create a Blueprint instance, Render reads this file and automatically provisions:
- A Docker web service built from the repository's Dockerfile
- A 1GB persistent disk mounted at
/data - An auto-generated security token for the gateway
- Health monitoring at the
/healthendpoint - A public HTTPS URL with automatic TLS
Step-by-Step Deployment
Fork the Repository
Go to the OpenClaw GitHub repository and click "Fork" to create your own copy. This lets you customize configuration files and receive upstream updates.
Create the Blueprint Instance
In the Render dashboard:
- Click New and then Blueprint
- Connect your GitHub account if you have not already
- Select your forked OpenClaw repository
- Render detects the
render.yamlautomatically
Set Environment Variables
Render prompts you for any variables marked sync: false. Enter your LLM provider API key:
| Variable | Value |
|---|---|
ANTHROPIC_API_KEY | Your Anthropic API key (sk-ant-...) |
The OPENCLAW_GATEWAY_TOKEN is generated automatically. You can view it later in the service's Environment tab.
Deploy
Click Apply to start the deployment. Render builds the Docker image, provisions the disk, and starts the service. The first build takes 3-5 minutes. Subsequent deploys from git pushes are faster due to layer caching.
Access Your Instance
Once the deploy completes and the health check passes, your instance is live at:
Find the exact URL in the service's header bar in the Render dashboard. Use the auto-generated gateway token (from the Environment tab) to authenticate.
Plan Comparison
| Feature | Free | Starter ($7/mo) | Standard ($25/mo) |
|---|---|---|---|
| Persistent disk | No | 1GB included | 1GB+ included |
| Always running | No (spins down after 15 min) | Yes | Yes |
| Custom domain | Yes | Yes | Yes |
| Auto TLS | Yes | Yes | Yes |
| Disk snapshots | No | No | Daily |
| RAM | 512MB | 512MB | 2GB |
| CPU | Shared | Shared | Dedicated |
| Best for | Testing/evaluation | Personal use | Team/production |
The free tier has two important limitations: the service stops after 15 minutes of inactivity (cold starts take 30-60 seconds), and there is no persistent disk, so all workspace data is lost on every restart.
Dashboard Features
Logs
The Render dashboard streams live logs from your service. Use the log viewer to debug startup issues, monitor agent activity, and track API requests. Logs are retained for 7 days on paid plans.
Shell Access
Render provides a web-based shell into your running service. Click Shell in the dashboard to open a terminal session inside the container. This is useful for inspecting configuration files, checking disk usage, or running ad-hoc commands.
Environment Variables
Add, edit, or remove environment variables from the Environment tab. Changes trigger an automatic redeploy. To add another model provider:
- Go to the Environment tab
- Click Add Environment Variable
- Set the key (e.g.,
OPENAI_API_KEY) and value - Save — the service redeploys automatically
Custom Domains
On any plan, you can attach a custom domain:
- Go to Settings and scroll to Custom Domains
- Add your domain (e.g.,
openclaw.yourdomain.com) - Update your DNS with the CNAME record Render provides
- Render provisions a TLS certificate automatically (typically within minutes)
Backups
On Standard plans and above, Render takes daily snapshots of your persistent disk. You can restore from a snapshot through the dashboard. On lower plans, implement your own backup strategy by periodically pushing workspace data to a git repository.
Scaling
Vertical Scaling
Upgrading your plan (e.g., from Starter to Standard) increases available RAM and CPU. This is the simplest way to improve performance and is done with zero downtime through the dashboard.
Horizontal Scaling
Running multiple instances of OpenClaw requires sticky sessions because the agent stores session state on the local persistent disk. Render supports sticky sessions via the X-Render-Origin-Server header, but this configuration is non-trivial. For most use cases, a single well-resourced instance is the better choice.
Security Best Practices
- Never share your gateway token. Treat it like a password. Render auto-generates a strong token, so you do not need to create your own.
- Use the default HTTPS URL. Render provides TLS out of the box. Do not disable it or proxy through an insecure endpoint.
- Restrict API key scopes. If your LLM provider supports scoped API keys, create a key dedicated to your OpenClaw instance with only the permissions it needs.
- Monitor the health endpoint. Set up Render's built-in alerting to notify you if the
/healthendpoint fails. - Review logs regularly. Look for unexpected authentication failures or unusual request patterns.
Troubleshooting
Service fails to start
Check the deploy logs in the Render dashboard. Common causes:
- Missing environment variable. The
ANTHROPIC_API_KEYor equivalent must be set before the first deploy. - Dockerfile build error. If you modified the Dockerfile in your fork, verify it builds locally with
docker build .first. - Health check timeout. The service must respond at
/healthwithin 30 seconds of starting. On the free tier with limited resources, startup can be slow.
Slow cold starts on the free tier
Free-tier services spin down after 15 minutes of inactivity. The next request triggers a cold start that takes 30-60 seconds while the container boots and the application initializes. This is expected behavior. Upgrade to a paid plan to keep the service running continuously.
Data loss on the free tier
The free tier does not include a persistent disk. All files written during a session are lost when the service restarts. This includes workspace data, conversation history, and configuration changes made at runtime. Use the Starter plan or above for persistent storage.
Deploy succeeds but service is unreachable
Verify the gateway is binding to 0.0.0.0 (not 127.0.0.1). Render routes external traffic to your container, which must listen on all interfaces. The render.yaml sets this correctly, but if you override it through an environment variable, the service becomes unreachable.
Out of disk space
Check disk usage from the Shell tab:
If the disk is full, delete old workspace files or upgrade to a larger disk through the Render dashboard. You can resize the disk without redeploying.
Updating OpenClaw
When a new version of OpenClaw is released:
- Sync your fork with the upstream repository
- Render detects the new commit and triggers an automatic deploy (if auto-deploy is enabled)
- Alternatively, click Manual Deploy in the dashboard
Your persistent disk data survives redeploys, so workspace files and configuration remain intact.