OpenClaw Commands & Prompt Reference

116 commands & parameters · 10 categories · Sources: OpenClaw docs (docs.openclaw.ai, 2026-10-10, newer than release 2026.9.9) — Slash commands and 9 more · Checked

Chat commands, hook events and a few terminal commands of OpenClaw, the self-hosted gateway connecting chat apps to AI agents, checked on 10 October 2026 against docs.openclaw.ai, which runs slightly ahead of release 2026.9.9 (the ultrafast setting of /fast is newer). Most slash commands must be the whole message; rows starting with openclaw run in a terminal on the Gateway host. Many are owner-only or need a commands flag. Skill-registered and QQBot-only commands are left out.

All Commands

Sessions and runs (10)

Command / SyntaxWhat it doesNotes
/new [model]Start a fresh sessionThe model may be an alias, provider/model or a fuzzy provider name; unmatched text becomes the message body.
/reset [soft [message]]Reset session in placeAdd soft to keep the transcript while startup reruns; /new instead archives the session and opens a new one.
/name <title>Name the sessionSent without a title, it shows the present name plus a suggested one.
/compact [instructions]Compact session contextHook handlers can bracket it with the session:compact:before and session:compact:after events.
/stopAbort the active runAlso stops that run's Gateway or sandbox commands; services started with background: true keep running.
/session idle <duration|off>Set thread idle expiryFor thread-bound conversations; success is reported only once the channel confirms the binding update.
/session max-age <duration|off>Set thread max-age expirySame confirmation rule as idle expiry: a failed channel update never produces a success reply.
/export-session [path]Export session as HTMLOwner-only; a given path overwrites an existing workspace file, and no path picks a collision-safe name. Alias /export.
/export-trajectory [path]Export a JSONL trajectoryWrites a JSONL bundle rather than the HTML view of /export-session; the short alias is /trajectory.
/btw <question>Ask a side questionUses the session as background but is never written to the transcript; in the Control UI it opens Side chat.

Run controls (9)

Command / SyntaxWhat it doesNotes
/think <level|default>Set thinking leveldefault clears the session override; /thinking and /t are aliases, and the levels offered follow the session's model.
/verbose on|off|fullToggle verbose outputMeant for debugging and risky in group chats because it can expose internals; the alias is /v.
/trace on|offToggle plugin traceBare /trace reports the current state; only plugin-owned debug lines appear, not full verbose output.
/fast [status|auto|on|off|ultrafast|default]Show or set fast modeProvider-specific: OpenAI and Codex start from priority; ultrafast is requested only when the Codex catalog advertises it.
/reasoning [on|off|stream]Toggle reasoning visibilityCan expose internal reasoning, so the docs advise keeping it off in group chats; alias /reason.
/elevated [on|off|ask|full]Toggle elevated modeA directive: sent alone it persists for the session, inside a normal message it acts only as a hint; alias /elev.
/exec host=<auto|sandbox|gateway|node> security=<deny|allowlist|full> ask=<off|on-miss|always> node=<id>Show or set exec defaultsHost and node placement persists for the session, while security and ask cover only the message they arrive in.
/queue <mode>Set run queue behaviorOne of the stripped directives, so the model never sees it; the Queue docs describe each mode.
/steer <message>Steer the active runAimed at a run already in progress, for example to correct course mid-task; /tell is the alias.

Models and sign-in (14)

Command / SyntaxWhat it doesNotes
/login [provider]Choose a sign-in providerOwner or admin only, from a private chat or Control UI session; it lists providers without starting sign-in.
/login refreshRefresh sign-in statusUse it when a chat login cannot be confirmed, then check /models; no second authentication is needed.
/login access <provider>Reopen model access choicesBrings back the choice between showing all provider models and keeping the current restrictions.
/login codexPair OpenAI Codex sign-inGoes straight to OpenAI device pairing; API keys and local setup use the Control UI handoff instead.
/login openrouterSign in to OpenRouterApprove in the browser, then come back to chat for the saved result; it needs the Gateway's managed HTTPS address.
/login cancelAbort a waiting sign-inAlso dismisses an open model-restriction question while saved credentials stay in place.
/model [name|default|list|status] [-s|--session|-a|--agent|-g|--global]Show or switch modelsPick by provider/model or alias, not by number; -a and -g also update agent or global defaults for owners and admins.
/model listBrowse providersSame listing as /models; on Discord the bare native command opens a dropdown picker instead.
/model statusShow model detailsCovers models, auth and endpoints, not token usage; /status and /usage handle that.
/model <model> -sSwitch model for this sessionLeaves configured defaults untouched; --session is the long form, and unscoped selections behave this way unless a scope is configured.
/model <model> -aSwitch and update agent defaultOwner/admin only; it rewrites just the current agent's configured primary, even if that agent inherited the global default.
/model <model> -gSwitch and update global defaultOwner/admin only; it changes the shared fallback in agents.defaults.model, not agents that set their own primary.
/model default -sReturn to the configured defaultDrops this session's model pin without writing any configured default; compatible auth pins are kept.
/models [provider] [page] [limit=<n>|all]List providers or modelsName a provider, as in /models openai, to see that provider's models; page and limit split long lists.

Discovery and status (15)

Command / SyntaxWhat it doesNotes
/helpShow short helpAn inline shortcut: it also works inside a normal message and is stripped before the model reads the rest.
/commandsShow the command catalogWhat appears depends on config flags, the channel surface, enabled plugins and installed skills.
/tools [compact|verbose]Show usable toolsAnswers for this agent, channel, sender and model right now; verbose adds short descriptions to the compact default.
/statusShow runtime statusIncludes provider quota when usage tracking is on; native Slack setups register it as /agentstatus because Slack reserves /status.
/status pluginsShow plugin health detailsNeeds commands.plugins: true and goes deeper than plain /status into failing, quarantined or incompatible plugins.
/goal [status|start|edit|pause|resume|complete|block|clear] ...Manage the session goalKeeps a durable objective for this session; the actions start, edit, pause, complete, block or clear it.
/dashboard [request]Build a session dashboardA reserved built-in name: a user skill called dashboard becomes /dashboard_2 and still runs through /skill dashboard.
/diagnostics [note]Start a support reportOwner-only; exec approval is requested on every run, so expect an approval prompt each time.
/openclaw <request>Run the setup helperSend it from a direct chat with the owner account and describe what should be set up or repaired.
/context [list|detail|map|json]Explain context assemblyShows what fills the model's window: system prompt, injected files, tool schemas, skills and history.
/context listList injected context sizesGives per-file sizes and totals, and still works from an estimate before any run report is cached.
/context detailBreak down context in depthAdds sizes per tool schema and skill entry, the system prompt size and how many transcript messages could be compacted.
/context mapDraw a context treemapReturns a picture of what takes up the window; it stays unavailable until a regular reply has created a run report.
/whoamiShow your sender idUseful when filling commands.allowFrom or commands.ownerAllowFrom, which match senders by id; /id is an alias.
/usage off|tokens|full|reset|costSet the usage footerreset returns to the configured default, and cost prints a local spending summary instead of changing the footer.

Skills, loops and approvals (7)

Command / SyntaxWhat it doesNotes
/skill <name> [input]Run a named skillAlways available, even for skills without a direct command of their own; skill names are sanitized to a-z0-9_.
/learn [request]Draft a skillThe result is a draft to review in Skill Workshop; add a request to point it at specific sources.
/loop [interval] <prompt>Repeat a promptOwner-only; /loop 5m check deploy status makes a fixed-cadence cron job, while no interval backs off toward hourly.
/loop statusList conversation loopsOwner-only; shows the cron-backed loop jobs that belong to this chat.
/loop stop [name]Stop loopsOwner-only; removes the matching cron-backed loop jobs, so name one to leave the others running.
/allowlist [list|add|remove] ...Manage allowlist entriesText-only; add and remove need commands.config: true and respect the channel's configWrites setting.
/approve <id> <decision>Answer an approval promptSettles exec, plugin and OpenClaw-change requests; /diagnostics, for one, raises an exec approval on every run.

Sub-agents and ACP (6)

Command / SyntaxWhat it doesNotes
/subagents list|log|infoInspect sub-agent runsScoped to the current session; completions are pushed back, so there is no need to poll it while waiting.
/subagents log <id|#> [limit] [tools]Show a sub-agent's recent turnsAdd the tools token to include tool calls and results, which are left out by default.
/subagents info <id|#>Show sub-agent run metadataUse it after a run ends to check its outcome, timing, cleanup and where the transcript lives.
/acp spawn|cancel|steer|close|sessions|status|set-mode|set|cwd|permissions|timeout|model|reset-options|doctor|install|helpManage ACP sessionsAlways handled by OpenClaw itself, even while the chat is bound to an ACP harness; runtime controls need owner or admin identity.
/session unbindDetach the conversationOnly on channels that keep persistent thread bindings; the agent session stays open for later use.
/agentsList thread-bound agentsOne of the thread-binding controls, alongside /session unbind and the idle and max-age expiry commands.

Config, plugins and admin (12)

Command / SyntaxWhat it doesNotes
/config show|get|set|unsetEdit openclaw.json from chatOwner-only and off until commands.config: true; writes are validated first and survive restarts.
/config set channels.whatsapp.responsePrefix="[openclaw]"Set one config valueTakes a dotted config path and a value; an invalid change is rejected before anything is written.
/mcp show|get|set|unsetEdit MCP server configOwner-only and needs commands.mcp: true; entries live under mcp.servers, and show redacts secrets.
/mcp set context7={"command":"uvx","args":["context7-mcp"]}Add an MCP serverThe JSON value holds the launch command and its arguments; /mcp unset with the same name removes it.
/plugins list|inspect|show|get|install|enable|disableManage plugins from chatNeeds commands.plugins: true; changes apply through the running Gateway without a restart, and /plugin is an alias.
/plugins install clawhub:<package>Install a ClawHub pluginClawHub and official-catalog installs skip the provenance warning that npm, git and local sources trigger.
/plugins install npm:<package> --forceInstall an npm plugin--force acknowledges the source after review; it does not override security.installPolicy or installer checks.
/plugins enable <plugin-id> --accept-capabilitiesEnable with capability consentRerun this way after the reply lists the plugin's declared capabilities; bundled and verified catalog plugins need no consent.
/debug show|set|unset|resetSet runtime-only overridesOwner-only and needs commands.debug: true; overrides reach new config reads at once but never the disk.
/restartRestart OpenClawOn by default through commands.restart; a non-owner gets a refusal quoting the configuration command for their sender id.
/updateUpdate OpenClaw from chatOwner-only; uses the Gateway update handler without needing a working model and reports the outcome in the same chat.
/send on|off|inheritSet send policyOwner-only; like other commands it accepts a colon after the name, as in /send: on.

Voice, shell and channel plugins (10)

Command / SyntaxWhat it doesNotes
/tts on|off|status|chat|latest|provider|limit|summary|audio|helpControl text-to-speechSubcommands switch speech on or off, pick a provider and set limits or summaries; the TTS docs explain each.
/activation mention|alwaysSet group activation modeOwner-only and for group chats; the stored mode overrides the group's requireMention on channels that use it.
/bash <command>Run a shell command on the hostOff unless commands.bash: true and tools.elevated allowlists permit it; the ! prefix is an alias.
!poll [sessionId]Poll a background shell jobClears the pending completion notice only once the final reply arrives; failed replies keep it.
!stop [sessionId]Stop a background shell jobTargets jobs that /bash moved to the background after its two-second foreground wait.
/dreaming [on|off|status|help]Toggle memory dreamingA bundled plugin command limited to the owner or a Gateway admin.
/pair [qr|status|pending|approve|cleanup|notify]Manage device pairingComes from a bundled plugin; subcommands cover QR codes, pending requests, approval, cleanup and notifications.
/voice status|list|set <voiceId>Choose a Talk voiceOn Discord the native command is registered as /talkvoice instead.
/codex <action> ...Control the Codex harnessActions include status, threads, resume, model, review, mcp and skills; with the codex plugin on, prefer it over ACP.
/card ...Send LINE rich cardsWorks only on the LINE channel and sends one of the preset card layouts.

Setup from the terminal (12)

Command / SyntaxWhat it doesNotes
openclaw setupOpen setup or chatOn a fresh machine it starts guided onboarding instead, the same flow as openclaw onboard.
openclaw setup --baselineCreate baseline folders onlySuits scripts; an invalid existing config is kept, and you are told to run openclaw doctor --fix first.
openclaw setup -m "status"Send one request to OpenClawRuns a single system-agent request; add --yes when that request has to write persistent config.
openclaw configureChange parts of a setupNeeds an interactive terminal; without one it prints matching openclaw config get or set commands and exits.
openclaw configure --section model --section channelsConfigure chosen sectionsThe flag repeats; sections are workspace, model, web, gateway, daemon, channels, plugins, skills and health.
openclaw channels addAdd a channel accountWithout credential flags it opens a guided wizard, which needs an interactive terminal; non-TTY shells exit at once.
openclaw channels add --channel telegramSet up one channel directlySkips the picker and opens that channel's guided setup; add --help to list the flags it accepts.
openclaw status --usageShow provider usagePrints each provider's remaining quota as a percentage left; add --agent to pick the auth profile scope.
openclaw status --allFull status diagnosisRead-only and safe to paste into a report, with a security audit, plugin compatibility and memory-vector checks.
openclaw updateUpdate OpenClawnpm, pnpm and bun installs use the package-manager flow; Docker users pull a new image and recreate the container.
openclaw update statusShow update statusWith no update running it shows the last recorded update and its start time; add --json for scripts.
openclaw update --channel betaSwitch to the beta channelThe choice is saved once the core update succeeds; stable, extended-stable and dev are the alternatives.

Hook events and commands (21)

Command / SyntaxWhat it doesNotes
command:newNew-session command handledAwaited before handling continues; previousSessionEntry in the context describes the session being replaced.
command:resetReset command handledAlso fires for a Gateway session reset, which sets commandSource to gateway:sessions.reset.
command:stopStop command handledFires after the abort request and cannot deliver a hook reply; it is not an agent-finalization gate.
commandEvery command eventAvoid subscribing one handler to both command and command:new, or it runs twice for each new command.
session:auto-resetDaily or idle resetContext gives the reason, daily or idle, plus the next session id when one exists.
session:compact:beforeCompaction about to startAwaited; session:compact is no wildcard, so subscribe to both compaction keys by name.
session:compact:afterCompaction finishedOnly after a successful run, with compactedCount and, when known, token totals before and after.
session:patchSession settings patchedAlso fires when /model or the model picker saves a change; a read-only status query does not.
agent:bootstrapWorkspace bootstrap stepHandlers may replace or extend the bootstrapFiles array, but deduplication and context budgets still apply.
gateway:startupGateway startedRuns after hooks and channels load without delaying the first bind; a hook reload does not replay it.
gateway:shutdownGateway shutting downRuns before channels and plugins are torn down; the wait is capped at five seconds by default.
gateway:pre-restartPlanned restart aheadOnly when shutdown expects a restart, with its own ten-second budget on top of the shutdown wait.
message:receivedInbound message acceptedObservation only, it cannot block processing; duplicate or session-less inbound updates may produce no event.
message:transcribedAudio transcript readyRequires a session key and non-empty speech text; the transcript itself arrives in the context.
message:preprocessedMedia and links preprocessedFires even when preprocessing was skipped, though fast native-command paths can bypass it entirely.
message:sentSend outcome reportedCheck context.success, and avoid blind resends on failure because part of the message may already be out.
openclaw hooks listList discovered hooks--eligible keeps only loadable hooks and -v adds a Missing column; bare openclaw hooks prints the same report.
openclaw hooks info <name>Show one hook's detailsAccepts a hook name or its hookKey and warns about unknown event names, which explains a hook that never fires.
openclaw hooks checkCheck hook eligibilityExits 0 even when hooks are not ready, so scripts should read the JSON counts instead.
openclaw hooks enable <name>Enable a hookWrites local config only, not a remote Gateway, and the entry applies globally even with --agent.
openclaw hooks disable <name>Disable a hookLeaves hook files and the master switch alone; plugin-managed hooks are toggled through openclaw plugins.

Recipes

Command sequences typed in chat to an OpenClaw gateway: signing in and choosing a model, then adding an MCP server.

Sign in from chat and switch the model for one session

/login codex → /model list → /model <model> -s

Run /login codex in a private chat or the Control UI to pair OpenAI, browse what is available with /model list, then pick a model with -s so configured defaults stay as they are. If the sign-in cannot be confirmed, /login refresh checks again without a second login.

Add an MCP server from chat

/mcp set context7={"command":"uvx","args":["context7-mcp"]} → /mcp show

With commands.mcp set to true, the owner can store a server under mcp.servers and read it back with /mcp show, which redacts secrets. /config is the general counterpart for other openclaw.json keys; /debug changes settings for the running process only.

Frequently Asked Questions

What is the difference between /config and /debug in OpenClaw?

/config writes validated changes to openclaw.json, so they survive a restart; invalid changes are rejected. /debug sets runtime-only overrides that new config reads pick up at once but that never reach the disk. Both are owner-only and stay off until commands.config or commands.debug is true.

How do I reset a session without losing the transcript?

Send /reset soft: the transcript stays, startup runs again and reused CLI backend session ids are dropped. Plain /reset resets the session in place, while /new archives it and opens a fresh one.

How do I set up OpenClaw from scratch?

Run openclaw setup in a terminal on the Gateway host. On a fresh machine it starts guided onboarding, the same flow as openclaw onboard; on a configured one it opens a chat with OpenClaw. openclaw setup --baseline only creates the config, workspace and session folders, and openclaw channels add connects chat accounts later.

Can I pick a model by its list number with /model?

No. In text commands, choose a model by provider/model or a configured alias; numeric choices such as /model 3 are not supported. On Discord, the bare native /model and /models commands open a dropdown picker instead.

Which OpenClaw chat commands are switched off by default?

/config, /mcp, /plugins, /debug and the /bash shell (with its ! prefix) stay disabled until their commands flag (commands.config, commands.mcp, commands.plugins, commands.debug, commands.bash) is true. /restart and /update are on by default through commands.restart.

Sources and checks

Every row on this page was matched to a line in the documentation above on . A command or parameter that could not be found there is not listed.

16 rows from the earlier version of this page were removed in that check: duplicates, and entries the documentation does not list or lists differently.

AI tools change their commands, parameters and model names between releases: the vendor's current documentation and the version you run have the last word. Found a wrong or missing entry? Tell us and it gets checked against the source. How we verify describes the process and its limits.

Related prompt references

Claude Code (157) · Aider (46) · Manus (47) · All AI prompt references