Back to Tutorials
Installation Guide Beginner March 10, 2026 20 min read

How to Install OpenClaw in 2026: 5 Different Methods (And Which One to Choose)

How to Install OpenClaw in 2026: 5 Different Methods (And Which One to Choose)

OpenClaw has rapidly become the standard for open-source, self-hosted AI agents, recently surpassing 250,000 stars on GitHub. It offers unprecedented local control—managing browsers, reading files, writing code, and autonomously creating skills.

However, recent architectural changes have rendered many older tutorials obsolete. Most notably, in January 2026, Anthropic deprecated the OAuth shortcut for Claude Pro and Max accounts in third-party tools.

This guide provides a definitive, up-to-date breakdown of the five primary installation methods for OpenClaw, helping you choose the right approach for your specific deployment needs.

Critical Prerequisite: The API Key Requirement

Before proceeding with any installation method, you must understand the current authentication landscape.

You can no longer use a Claude Pro or Max subscription via OAuth. Anthropic's compliance policies now strictly require an API key on a pay-as-you-go plan for third-party integrations.

  • Navigate to the Anthropic Console.
  • Add a valid billing method (required even if you have free credits).
  • Generate a new API key.

Cost Warning: OpenClaw is highly agentic. A single user prompt may trigger 5 to 10 API calls, with each call transmitting the entire conversation context. Without proper model routing, a long session can consume hundreds of thousands of tokens.

Method 1: The Automated Script (Recommended for Most Users)

This is the officially supported method and the fastest path to a working local instance. The script automatically verifies your Node.js version (v22+ required), installs dependencies, and launches the Terminal User Interface (TUI) onboarding wizard.

Who should use this: First-time users and those who want a streamlined local setup without manual configuration.

Execution:

For macOS and Linux:

curl -fsSL https://openclaw.ai/install.sh | bash

For Windows (PowerShell):

iwr - useb https: // openclaw.ai / install.ps1 | iex

Once installed, initiate the onboarding process:

openclaw onboard

Method 2: Package Manager Installation (Best for Developers)

If you already maintain a Node.js environment and prefer managing dependencies via npm or pnpm , this method allows you to scaffold OpenClaw directly into an existing project structure.

Who should use this: Developers comfortable with Node.js who want granular control over the project directory.

Execution:

Ensure you are running Node.js v22 or higher:

node --version

Scaffold the project:

npx openclaw init my-assistant

cd my-assistant

Start the configuration wizard:

npx openclaw onboard

Method 3: Docker Deployment (Best for Servers and Homelabs)

Containerizing OpenClaw provides strict environmental isolation, making it the ideal choice for dedicated servers, NAS devices, or cloud VMs. It prevents OpenClaw's dependencies from conflicting with your host system.

Who should use this: System administrators, homelab enthusiasts, and users deploying to remote servers.

Execution:

Create a docker-compose.yml file:

version : '3.8'

services :

openclaw-gateway :

image : openclaw/gateway:latest

ports :

- "18789:18789"

volumes :

- ~/.openclaw:/root/.openclaw

restart : unless-stopped

Deploy the container:

docker-compose up -d

Execute the onboarding wizard inside the running container:

docker exec -it openclaw-gateway openclaw onboard

Method 4: Cloud 1-Click Deploy (Best for Zero-Maintenance)

Providers like DigitalOcean now offer pre-configured OpenClaw images. This method provisions a Virtual Machine (Droplet) with OpenClaw and all dependencies pre-installed.

Who should use this: Teams requiring a shared instance, or users who want 24/7 uptime without managing local hardware.

Execution:

  • Deploy the OpenClaw 1-Click App from your cloud provider's marketplace.
  • SSH into your newly provisioned server:

ssh root@your_server_ip

  • Run the initialization command:

openclaw onboard

Note: This method incurs standard cloud hosting fees in addition to your LLM API costs.

Method 5: Build From Source (Best for Contributors)

Compiling OpenClaw from source provides complete visibility into the codebase, allowing for custom modifications and security audits.

Who should use this: Open-source contributors, security researchers, and developers building custom forks.

Execution:

Clone the repository and install dependencies:

git clone https://github.com/openclaw/openclaw.git

cd openclaw

npm install

Build the project:

npm run build

Link the binary globally and start onboarding:

npm link

openclaw onboard

Post-Installation: Critical Configuration Steps

A successful installation is only the first step. To ensure security and cost-efficiency, you must configure the following settings immediately.

1. Implement Model Routing

Do not use frontier models (like claude-3-opus ) for basic tasks. Edit your configuration to route simple requests to cheaper models.

openclaw config edit

Add the routing configuration:

"models" : {

"default" : "claude-3-haiku-20240307" ,

"complex" : "claude-3-5-sonnet-20240620"

}

2. Secure the Canvas Host

By default, the web UI might be exposed to your local network. Restrict it to localhost to prevent unauthorized access.

"gateway" : {

"host" : "127.0.0.1" ,

"port" : 18789

}

3. Audit Third-Party Skills

The ClawHub marketplace contains thousands of community-contributed skills. Recent security analyses indicate that up to 20% of unverified skills may contain vulnerabilities or malicious code.

Always review the source code of a skill before installation. If you cannot audit the code, restrict your usage to officially verified skills with high download counts.

4. Understand the Memory Architecture

OpenClaw stores conversation history and learned preferences as plain-text Markdown files (e.g., memory/2026-03-02.md and MEMORY.md ).

To view your current memory state:

cat ~/.openclaw/workspace/MEMORY.md

Ensure this directory is properly secured, as it contains sensitive personal data and operational context.