Clicky

OpenClaw Full Tutorial for Beginners: How to Setup Your First AI Agent (ClawdBot)

OpenClaw Full Tutorial for Beginners: How to Setup Your First AI Agent (ClawdBot)

Most people who try OpenClaw fall into one of two groups. The first never installs it at all — too unsure, too worried about breaking something. The second installs it, gets excited, tries to do everything on day one, burns through tokens and time, and quietly stops using it by the weekend.

This walkthrough is for both groups. It takes you from a blank spare device to a working agent you can message from Telegram, then shows you the small first-week routine that actually sticks.

You don't need to be a developer. You need a spare machine, twenty minutes, and the willingness to accept defaults on the first pass and refine them later.

By the end you'll have a locked-down instance, a daily task running at 8 a.m., and a clear sense of what to add next — without the overreach that kills momentum.

Quick Tips Before You Start

💻

Use a spare device

An old laptop, a Mac Mini, a Raspberry Pi, or a VPS — never your daily driver with saved passwords.

💵

Start with $5–$10

That's enough OpenRouter credit to get through the first week of light use.

🔑

Keep tokens secret

Your bot token and dashboard URL are passwords. Don't paste them into chats or screenshots.

🛡️

Run the audit early

Ask for a security audit and redaction setup before you give the agent real tasks.

🎯

One task first

Start with a single daily automation, not five. Add scope once the first one runs cleanly.

1. Give OpenClaw its own device, not your main one

Give OpenClaw its own device, not your main one

You're on the couch with your everyday laptop open, install command copied, cursor blinking in the terminal, and that's the exact second to stop.

Ask what's on this machine. Saved passwords, work documents, logged-in email, banking. If it has any of those, it's the wrong machine, because a compromised agent inherits everything the computer can already reach. Every password manager vault, every open session, every file in your home folder. A spare device with nothing sensitive on it contains the damage.

You have four realistic options. An old laptop or spare desktop, a Mac Mini, a Raspberry Pi, or a VPS. The walkthrough here uses a Pi 5 with 8GB RAM and a 32GB SD card running 64-bit Raspberry Pi OS, and the same install works identically on the other three.

For example: that five-year-old laptop in the drawer with a fresh OS and no logins is a perfectly good agent host. It costs nothing, and wiping it later costs nothing either.

Pick the machine by asking one question. If it got taken over tomorrow, what would you lose? If the answer is a weekend of setup and nothing else, it's the right box.

💡 Tip: A Raspberry Pi 5 with 8GB RAM idles at a few watts and costs less than a month of cloud hosting. If you have one in a drawer, use it.

ModelInputOutputUse it for
Cheap open-source model$0.30$1.10Daily driver, routine tasks
Claude Sonnet 4.6——The walkthrough model; a middle ground
Claude Opus 4.6$5.00$25.00Hard reasoning, occasional use
The two ends of the OpenRouter price range, per million tokens

2. Start from a blank slate, not a one-click image

Start from a blank slate, not a one-click image

With the spare device decided, the next choice is how OpenClaw gets onto it, and the answer is not the shiny one-click route.

That means DigitalOcean's OpenClaw image or Hostinger's 1-click OpenClaw button. Both give you a running instance in minutes with no terminal work, and the catch arrives later: pre-configured settings can be difficult or impossible to change once you actually know what you want.

Use a one-click only for a throwaway test you fully intend to delete. For the instance you keep, start from a blank slate and install it yourself.

3. The install command does three jobs at once

The install command does three jobs at once

Because you chose the blank slate, the install is a single command, and it does three jobs in a row.

It checks the device for prerequisites and downloads anything missing, it installs OpenClaw, then it finalizes and launches onboarding. All of it in a terminal on the dedicated device itself, not on the computer you're reading this from.

Get the exact command text from the project's own install page rather than retyping it from a screenshot. One wrong character is a frustrating afternoon.

Then leave the terminal alone. It's one continuous session that ends with the onboarding screens, and closing the window mid-run means starting over.

4. First pass: minimum settings, then wipe and redo it

First pass: minimum settings, then wipe and redo it

Almost nothing, and that's on purpose.

Accept the defaults, change the bare minimum, and just use it for a few hours or a day. That gives you a feel for what the agent can do before you commit to settings you don't yet understand. Then wipe OpenClaw, rerun onboarding, and set security and options deliberately. The project's own security doc is honest that no setup is perfectly secure. The goal is control over who can talk to your bot, where it can act, and what it can touch.

Before you wipe, save your Telegram bot token and your markdown files somewhere safe, so the reinstall costs you neither the bot connection nor your notes.

Think of it like a rough draft. A day of defaults tells you more about your real needs than an hour of guessing at settings.

💡 Tip: Two installs, one afternoon. The second one is faster because you already know which screens are coming.

5. One OpenRouter key unlocks nearly every model

One OpenRouter key unlocks nearly every model

Unlike the wipe-and-redo freedom of a rough first pass, this second install asks you to commit to a key and a model, so choose the one that keeps your options open.

That's OpenRouter, because a single key covers OpenAI, Google, Anthropic and a long list of open-source models. Create the account, add $5 to $10 of credits, head to the API keys tab, create a key, name it, and paste it into onboarding.

The walkthrough model is Claude Sonnet 4.6. If budget matters, use a cheap open-source model as your daily driver, quoted near 30 cents per million input tokens and $1.10 per million output, against Claude Opus 4.6 at $5 in and $25 out. Save the expensive models for hard reasoning.

⚠️ COMMON MISTAKE

Don't reuse your main API keys

When you create the OpenRouter key, give it its own name and treat it as disposable. If you later suspect a leak, you can revoke and replace that one key without touching anything else you use.

6. Accept the warning, pick manual, keep it local

Accept the warning, pick manual, keep it local

Say yes to the security warning, then pick manual onboarding when the quick option appears. That is the safe default path for a first install, and every choice after it has a reason you can point to.

Accept the default working directory, keep the gateway bind on loopback, use the recommended generated token, and leave Tailscale disabled. Loopback means only that device can reach the gateway. The token is the password to the dashboard. Tailscale would put the agent on a private network, so leave it off until you specifically need remote access.

If a port is already occupied by an existing instance, choose a different port. That's normal on a reinstall, not a broken install.

Here's a quick worked example: on a Pi running a second install after a wipe, port 3000 is taken by the leftover instance. Pick 3001, finish onboarding, and the dashboard opens cleanly. Nothing was wrong with the install; you just answered the same question twice.

Skip quick onboarding for now not because it's bad, but because manual shows you each step once. That single pass is what makes the next screens legible.

7. Wire it to Telegram with a BotFather bot

Wire it to Telegram with a BotFather bot

With the security choices settled, the onboarding asks for a channel next, and that's the connection that lets you talk to your agent from your phone. Telegram is the one to pick.

In Telegram, message BotFather, send /newbot, and enter a display name when asked. The second name must end in 'bot' and use underscores where you'd use dashes, so something like test_agent_bot is fine but test-agent-bot isn't.

Copy the bot token BotFather hands back, paste it at the channel setup step, then choose Finished. Treat that token as a password. Anyone who has it can drive your bot, so it goes nowhere near a chat thread or a public gist.

8. Allowlist your Telegram ID so nobody else can chat

Allowlist your Telegram ID so nobody else can chat

Choose an allowlist over open DM access so only people you name can talk to your agent. An allowlist of user IDs is the difference between a private assistant and a bot anyone who finds it can message.

Finding your ID is the fiddly part. Open your own Telegram profile and read the digits in the page URL. Copying the username often fails in this setup, so use the number, and paste the digits only, nothing else.

When you want to add a teammate later, edit the allowlist rather than opening the bot up to everyone. Two or three names is still private; the open setting never is.

💡 Tip: If the allowlist step rejects your ID, the most common cause is a stray space or a copied @ symbol.

9. Skip the skills, decline extra keys, enable hooks

Skip the skills, decline extra keys, enable hooks

Right when the channel is wired up and you're eager to get chatting, the next screens ask about skills and extra API keys, and this is where most people overreach. Skip them all for now.

Skills are plug-in tools you can add any time later, so press spacebar to select skip, then enter. Answer no to every additional API key prompt.

Then enable all hooks, install the gateway service and Node, and enable bash. Every extra moving part is another thing to debug before you know the install itself works.

⚙️ From install command to first reply

1

Paste the install command

Run it in a terminal on the dedicated device and let it finish.

2

Accept the warning, choose manual

Keep the gateway on loopback and use the recommended token.

3

Add the OpenRouter key

Paste the key and pick a model — Sonnet 4.6 or a cheap open-source one.

4

Create the BotFather bot

Send /newbot, name it, and paste the token into the channel step.

5

Allowlist your Telegram ID

Paste the digits from your profile URL so only you can chat.

6

Skip skills and extra keys

Enable hooks, install the gateway service, and enable bash.

7

Open the dashboard and say hello

Confirm a reply comes back before you give it any real task.

10. Open the tokenized dashboard URL and say hello

Open the tokenized dashboard URL and say hello

Onboarding finishes by printing a dashboard URL that already contains its token, and that link is how you check the install actually worked. Copy the whole thing, paste it into the terminal, and open the dashboard.

Send a simple greeting and confirm a reply comes back before doing anything else. A working reply is your proof the install, the key and the model are all talking to each other.

That URL is a credential. Don't paste it into chats, screenshots or a shared notes app. If it leaks, anyone who opens it has your dashboard, so keep it in your own browser bar and nowhere else.

If you get no reply, don't start tweaking settings. Check the API key and the model name first, because those are the two most common causes of silence at this stage.

Is Your Install Actually Ready?

✓
🔑 OpenRouter key acceptedThe agent replies to a greeting without an error.
✓
🤖 BotFather token pastedThe Telegram bot exists and responds to your message.
✓
🛡️ Allowlist contains only your IDNo usernames, no extra digits, no blank entries.
✓
🌐 Gateway bound to loopbackTailscale is off and the port isn't exposed publicly.
!
📉 No plain-text secrets in logsRun the redaction prompt and re-read the output.
Rule of thumbIf any point is amber, fix it before the first automation.

11. The first conversation is the agent's onboarding

The first conversation is the agent's onboarding

So the greeting landed and you're staring at the cursor wondering what to type. Here's the short version: you're briefing a new assistant, not making conversation.

Cover three things in that first chat. Tell it what role it plays, who you are, and the goals you're working toward. That's it. Budget five to ten minutes, send something rough, and move on. A brief that's 80 percent right beats a perfect one you never finish writing.

This first conversation isn't a one-off, either. Every new agent you spin up later, whether it's a research one or a writing one, gets the same onboarding chat before it does anything useful.

And expect to rewrite all of it. Once you've watched it work for a week and seen what you actually ask it for, the goals you wrote on day one will look vague. That's normal. Rewriting is the job, not a failure.

12. Its memory lives in markdown files you can edit

Its memory lives in markdown files you can edit

Unlike hidden settings buried in a menu, everything the agent learns about you sits in plain markdown files you can open, read and change at any time. That first onboarding conversation doesn't vanish when you close the chat; the agent writes it down.

agents.md is the instruction set loaded into every single conversation. bootstrap.md drives that first-run onboarding and is where its personality gets built, soul.md is the personality and character itself, identity.md is the agent's role once you've defined it, and user.md holds your name, time zone, how you like to be talked to and your project context. Open user.md and you'll likely find your own words in it.

The useful trap here is treating these as fixed. As the work grows you add files the same way: research.md for reading notes, travel.md for trip planning, each one a new shelf the agent can pull from. When you want it to talk to you differently, just ask it to update its own config file, and it edits these directly. Skim them once a week so you know what it believes about you.

💡 Tip: Read agents.md once after the first week. It's the single file that shapes every reply you get.

13. Reset the session, then test Telegram for real

Reset the session, then test Telegram for real

It's the next morning, the coffee's going, and you want to message your agent from your phone instead of walking to a screen somewhere. Time to make Telegram the interface you actually use.

First, reset the session after that first conversation so the onboarding chat doesn't bleed into real work. Then open the bot chat in Telegram and send a message to confirm the connection works.

Telegram as the default is the practical call: it lives on your phone and reaches you anywhere. The dashboard doesn't. If the bot stays silent, check the allowlist ID and the bot token before anything else.

14. Run a security audit before real tasks

Run a security audit before real tasks

A working bot is not the same as a safe bot, and this is the step nearly everyone skips because they're excited. Before you trust the agent with anything real, harden the setup.

Ask it to run a security audit of the device and of the OpenClaw deployment, and to list any issues worth fixing. This works because it knows how OpenClaw was built and has commands for audits and health checks, so it can genuinely inspect the machine rather than guess.

The important part comes next: read and understand the response instead of blindly approving it. If an item is about opening a port to the internet, you want to know that before it happens.

Then reply telling it to fix everything you agree with. On the Pi 5 walkthrough, for example, a couple of items will be harmless housekeeping and one might be a permission change worth a second look.

Two minutes of reading here saves a much bigger cleanup later.

💡 PRO TIP

Run the audit twice

Run it once, apply the fixes, then run it again. The second report shows what changed and catches anything the first pass missed.

15. Turn on redaction so keys stay out of logs

Turn on redaction so keys stay out of logs

So the audit's done, and the obvious next question is what else to lock down while you're in the mood. Redaction.

OpenClaw has a built-in feature that redacts secrets from log metadata, so API keys and user IDs don't end up in places you never intended. In the walkthrough, running the scan surfaced tokens that had been stored as plain text and recommended hardening them.

Reply that you agree with all the recommendations and the agent applies the fixes itself. No hand-editing config files required.

The audit prompt plus this one roughly double the instance's security for a couple of minutes' work. That's the best return you'll get all day.

16. Add free web search with a Brave API key

Add free web search with a Brave API key

Once the audit and redaction are done, the next thing to hand the agent is a job: looking things up. A model with no search is stuck in its training data, so give it live access. There are two default routes here — Brave Search, or Perplexity, which you can reach through OpenRouter.

Brave's free plan is the simpler one: no credit card, 1 request per second, 2,000 requests per month. That's plenty for casual use. The catch is the rate limit — tell the agent to space its requests out so it stays inside it, or a burst of lookups will get refused.

Create the account, add an API key with a name you'll recognize, and copy it. Supply it by telling the agent in chat or running the config command, then enable Brave web search plus web fetch. Ask it to call the Brave API and report whether it worked — a quick yes or no tells you the key is live.

💡 Tip: 2,000 requests per month is plenty for daily briefings. You'll hit the per-second limit before the monthly cap.

17. Start with one small daily task in plain English

Start with one small daily task in plain English

You've now got an agent that's secured, redacted and can search the web — and the temptation is to automate everything at once. Don't. Start with one task and keep it small.

The example that works well is asking, in plain English, for the latest AI news every day at 8:00 a.m., before you hand business tasks to AI agents. No special syntax, no config file, just the request. Run it for a couple of rounds before you add anything to it, because a task you've watched succeed twice is a task you actually understand.

Once it's steady, extend it: the weather, a short research report, a few video ideas. The agent can revise its own scope of work when you ask, so the task grows with you instead of being rebuilt from scratch each time.

If a daily task fails on the second morning, check the schedule first. Time zones are the usual culprit, not the model — a task set for 8:00 a.m. in the wrong zone will fire at the wrong hour. Keep the first one small enough that you'd notice straight away if it stopped running.

First week: what to do and what to hold off on

✅

Do this

  • Run the security audit and redaction prompts
  • Start one 8 a.m. task and run it twice
  • Send voice notes describing your goals
  • Let the agent build research.md and travel.md
⛔

Hold off on

  • Spawning three extra agents on day one
  • Adding every skill and API key at once
  • Tuning model settings before you know your use case
  • Pasting the dashboard URL into shared notes

18. Don't spawn agents yet — brain-dump by voice note

Don't spawn agents yet — brain-dump by voice note

Resist deploying two or three extra agents before you understand the tool. It burns tokens and time, and it's the fastest way to lose momentum on something that was just starting to work.

Send voice notes instead — what's on your mind, your goals and your tasks. Have the agent create files like research.md and travel.md and sort the tasks into them as they go. After a few days, ask the main agent to spin up multiple agents from those files, so each one starts with context instead of a blank page.

If a token leaks or the bot misbehaves

If a token leaks or the bot misbehaves

Cut access first. Remove the entry from the Telegram allowlist and generate a fresh bot token in BotFather before you investigate anything else, because the old credentials stay valid until you replace them. Doing this in the wrong order leaves a working door while you read logs.

Next, rotate the OpenRouter key and the Brave key, and update them wherever the agent is using them — the chat config, the environment file, or both. A key you've replaced but not updated will simply fail, which is far better than one that still works for someone you've never met.

Then re-run the security audit and the redaction prompts, and read what has changed since last time. The report tells you whether the leak was a one-off or a pattern. Then check the agent's logs for messages you didn't send.

If anything looks unfamiliar, a full wipe and clean reinstall is the safer move than trying to patch a machine you no longer trust. None of this is dramatic if you've kept the blast radius small — and that's the whole reason the agent lives on a spare device with an allowlist. Small, separate, easily thrown away.

Frequently Asked Questions

Do I need a Raspberry Pi to run OpenClaw?

No. Any spare device works — an old laptop, a Mac Mini, or a small VPS. The install steps are identical. The Raspberry Pi is just a low-power, low-cost option that's easy to leave running.

How much does the first week cost?

The OpenRouter credit is the main cost, and $5–$10 is enough for light use. Brave Search's free plan covers web search at no charge. A cheap open-source model keeps token costs near zero for routine tasks.

Can I skip the security audit?

You can, but it's the cheapest insurance in the whole setup. The audit takes a couple of minutes and is the step that turns a working install into a reasonably safe one. Run it before the agent gets any real task.

Why didn't my Telegram bot reply?

Check two things in order: the allowlist entry (digits only, no username and no stray spaces) and the bot token pasted during channel setup. If both are correct, confirm the gateway is still running on the device.

Should I use the dashboard or Telegram day to day?

Telegram, for most people. It's on your phone and reachable anywhere, while the dashboard lives on the device. Keep the dashboard for setup and debugging, and use Telegram for actual conversation.

What if I pick the wrong model at setup?

You can change it later in the config or by asking the agent. Start with Sonnet 4.6 or a cheap open-source model, use it for a few days, then switch if the responses feel too slow, too costly, or not sharp enough.

Pick the spare device today and leave the settings alone

Here's the close: pick the spare device, run the installer with defaults, and don't tune anything yet. That's the whole first day.

Then follow the first-week sequence. Run the security audit and the redaction prompt. Set one 8 a.m. task and let it run twice. Send one voice-note brain dump and let the agent sort it into markdown files.

A reader who does only those four things is further ahead than one who configured everything on day one and burned out by Thursday. The defaults are fine for now. The deliberate tuning comes after you know what you actually want.

Run the two security prompts before anything else

Scroll back to entries 14 and 15, copy those two prompts, and send them in Telegram. Two minutes now saves a much larger cleanup later.