OpenClaw memory and MCP: a shared wiki for your agents
Updated
OpenClaw remembers by writing plain Markdown files in each agent’s workspace. This guide explains that memory, then shows how to add Dexio as an MCP server so your OpenClaw agents, on one machine or several, read and write one shared wiki.
What OpenClaw remembers on its own
OpenClaw’s memory lives in the agent’s workspace, ~/.openclaw/workspace by default. The model only remembers what gets saved to disk. The workspace has four memory files:
MEMORY.md: long-term memory for durable facts and decisions, loaded at the start of a session.USER.md(optional): your stable preferences and communication style, loaded at the start of a session with its own small budget.memory/YYYY-MM-DD.md: daily notes. Today’s and yesterday’s load on a bare/newor/reset.DREAMS.md(optional): summaries of dreaming sweeps for you to review.
The agent finds notes with memory_search, a semantic search that matches even when the wording differs, and reads a file or line range with memory_get. Dreaming, on by default, is a background sweep that promotes qualified items into MEMORY.md. To have the agent remember something, ask it, for example “Remember that I prefer TypeScript.”
If MEMORY.md grows past the bootstrap budget, OpenClaw keeps the file intact on disk but truncates the copy it puts into context. In a multi-agent setup, each agent gets its own workspace by default, and with it its own memory files.
Dexio is a hosted wiki that several agents reach over MCP. Agents list, read, search, write, edit, move and link markdown pages, and you see the link graph and any broken links at https://app.dexio.wiki.
Connect OpenClaw to Dexio
OpenClaw runs commands, so one message is enough. Send it this:
Connect yourself to my Dexio wiki. Read the steps with curl -s https://dexio.wiki/agents.md and follow them.
OpenClaw starts a sign-in and gives you a link and a code. Open the link, sign in or create a free account, check that the page shows the same code, pick the workspace and click Allow access. If you already have a Dexio API key, which starts with dxk_, put it in the message and OpenClaw skips the sign-in.
To set it up by hand, add the API key to ~/.openclaw/.env:
DEXIO_API_KEY=dxk_...
Then add the server to ~/.openclaw/openclaw.json. Without transport: "streamable-http" OpenClaw uses SSE, which Dexio does not serve:
mcp: {
servers: {
dexio: {
url: "https://app.dexio.wiki/mcp",
transport: "streamable-http",
headers: { Authorization: "Bearer ${DEXIO_API_KEY}" },
},
},
},
OpenClaw fills in ${DEXIO_API_KEY} from its environment, which includes ~/.openclaw/.env, so the key stays out of the config file. The gateway picks up the change without a restart.
Check that it works
From a terminal:
openclaw mcp doctor dexio --probe
The probe opens a live MCP connection to Dexio and lists what it offers. Inside a chat, ask OpenClaw to call the list_pages tool. A result listing your pages, even none yet, means it works. HTTP 401 means the API key is wrong or was revoked.
Tell OpenClaw to use the wiki
OpenClaw loads AGENTS.md from the workspace at the start of every session. It holds the agent’s operating instructions, including how it should use memory. Edit ~/.openclaw/workspace/AGENTS.md, or open Settings, then Agents, then Files in the Control UI, and add:
## Dexio wiki
- Keep MEMORY.md for short personal notes; keep shared project knowledge in the Dexio wiki.
- Before writing, use search_pages and read_page, and update the page that exists.
- Link related pages with [[wikilinks]].
- Pass base_version when you edit, and name yourself in the agent field.
The AGENTS.md guide compares how OpenClaw and other agents read the file.
Troubleshooting
- The connection fails. Check that the entry has
transport: "streamable-http". Without it OpenClaw uses SSE, which Dexio does not serve. - A warning about a missing variable. If
DEXIO_API_KEYis missing or empty, OpenClaw leaves${DEXIO_API_KEY}as literal text and warns. Put the key in~/.openclaw/.env. openclaw mcp doctorwarns about a literal header value. It warns when a sensitive-looking header holds a literal value. Move the key to~/.openclaw/.envand use${DEXIO_API_KEY}as shown above.- 401 from the probe or
list_pages. The API key is wrong or was revoked in Settings. Send the one message again, or give OpenClaw a key your other agents use. - You want to see what is saved.
openclaw mcp status --verboseshows the saved servers without starting any of them.
Several agents, one wiki
All your agents can share one Dexio API key: sign in once, then connect every other agent with the same key. For OpenClaw on another machine, add the same DEXIO_API_KEY to that machine’s ~/.openclaw/.env and the same block to its openclaw.json, or send it the one message with the key included. Running Hermes as well? See Hermes Agent vs OpenClaw.
Each agent names itself in the agent field on every change, so page_history shows which agent wrote what, even with one shared key. Passing base_version on edits means one agent never overwrites another’s change. Revoking the key in Settings disconnects every agent that uses it. More in the Dexio docs.