Skip to main content
Installation connects Memory Crystal to your AI client and chooses where the data lives.

Agent Instructions

Paste this prompt into your agent to install and verify Memory Crystal. Automatic recall injection remains opt-in even on Full hosts.

Primary installer

https://memorycrystal.ai/crystal redirects to /install.sh. It is not a separate installer. Bash (macOS, Linux, WSL, Git Bash):
Native Windows PowerShell:
An interactive run detects clients and asks before it changes each one. --targets selects clients explicitly and skips that prompt. --yes accepts the default for each prompt and implies --non-interactive. --non-interactive fails if a required value (such as an API key) is missing. --dry-run prints the plan and writes nothing. Every config edit is backed up first. JSON and TOML are validated before and after the write, and a failed validation restores the backup. API keys, bearer tokens, and device codes are redacted from logs.

Targets

Bash targets: claude-code, claude-desktop, codex-cli, codex-desktop, opencode, factory-droid, hermes, openclaw, cursor, grok, generic-mcp. PowerShell accepts that list except hermes. Shared hooks are installed only by Bash. PowerShell logs that it skipped them when the platform row sets hooks.shells to bash. Skills can still be copied. The Managed Block and instructions.md are not written by PowerShell.
Codex CLI and Codex Desktop share ~/.codex/config.toml (CODEX_HOME overrides the directory). Configuring either target writes that file, so both surfaces pick up the MCP server. Uninstalling either target removes that shared block.

Install one client

Choose one command for the client you want to configure. Hermes and the native OpenClaw plugin need Bash. PowerShell configures MCP and skills where supported; it skips Bash-only hooks. Factory Droid is a Tools-tier installer target.
The PowerShell target provides generic MCP guidance. Use Bash for the native plugin.

Official platforms and other hosts

The tier comes from hooks.inject and tier in the platform table. Cursor is Full in that table. It is absent from the separate official-publication list. That is a publication difference, not a missing installer. See Support Tiers.

Agent identity

Every install writes a non-empty agentId to ~/.memory-crystal/config.json. The value is the platform slug (claude-code, codex, grok, openclaw, hermes, cursor, and the other rows). Codex CLI and Codex Desktop both use codex. Hooks resolve identity in this order:
  1. agentId or agent_id on the hook input
  2. MEMORY_CRYSTAL_AGENT_ID
  3. the host identity from --host or host detection
  4. agentId in ~/.memory-crystal/config.json
Clearing agentId in the shared config does not remove an identity the host hook still passes. A pre-existing user-set agentId is not overwritten on re-run. A knowledge base whose allow-list does not include that slug is hidden from the agent. The installer prints a reach report in the same run (counts and names, never contents). Add the slug on the dashboard (Knowledge → Agents) or call crystal_set_knowledge_base_access with action=add. See Scoping and access.

Backends

Read Local-First Setup before local mode. Self-hosting guides: Self-Hosting, Railway, Environment variables. A supplied API key is validated with GET /api/mcp/auth before any client config is written. Browser device sign-in runs only when no key is set and the shell is interactive.

Single-client scripts

These remain for a focused install:
OpenClaw and Hermes use the primary installer.

After install

  • Confirm tools with crystal_wake, crystal_remember, and crystal_recall.
  • Keep the printed backup path until the client works.
  • Skills are instructions. They do not enable capture or injection. See Skill Suite.

Client guides