In MiMo Code, environment variables are not a general fallback for the config file. They serve four distinct roles: locating resources, runtime switches, compatibility and skipping, and auth and endpoints. Config fields (such as model / permission / server.port) are not read automatically from same-named environment variables; they must be injected explicitly via MIMOCODE_CONFIG or MIMOCODE_CONFIG_CONTENT.
Boolean variables follow a consistent rule: true / 1 means on, false / 0 means off; any other value or unset uses the default.
| Variable | Type | Default | Effect |
|---|---|---|---|
MIMOCODE_HOME | string | — | Single profile root (holds config/, data/, state/, cache/), overrides all XDG base dirs, must be an absolute path |
MIMOCODE_CONFIG | string | — | Custom config file path |
MIMOCODE_CONFIG_DIR | string | — | Custom config directory (same structure as .mimocode/) |
MIMOCODE_CONFIG_CONTENT | string | — | Inline JSON config content |
MIMOCODE_TUI_CONFIG | string | — | Custom TUI config file path |
MIMOCODE_PERMISSION | string | — | Inline JSON permission config |
MIMOCODE_DB | string | — | Override the database file path |
MIMOCODE_MODELS_URL | string | — | Custom model manifest fetch URL |
MIMOCODE_MODELS_PATH | string | — | Custom model manifest local path |
MIMOCODE_GIT_BASH_PATH | string | — | Path to the Git Bash executable on Windows |
| Variable | Type | Default | Effect |
|---|---|---|---|
MIMOCODE_PURE | boolean | false | Pure runtime mode, disables all plugins |
MIMOCODE_AUTO_SHARE | boolean | false | Auto-share sessions |
MIMOCODE_DISABLE_SHARE | boolean | false | Fully disable sharing |
MIMOCODE_DISABLE_AUTOUPDATE | boolean | true | Disable auto-update checks; set false to enable |
MIMOCODE_ALWAYS_NOTIFY_UPDATE | boolean | false | Notify of new versions even when auto-update is disabled |
MIMOCODE_DISABLE_AUTOCOMPACT | boolean | false | Disable automatic context compaction |
MIMOCODE_DISABLE_PRUNE | boolean | false | Disable pruning of old data |
MIMOCODE_DISABLE_TERMINAL_TITLE | boolean | false | Disable automatic terminal title updates |
MIMOCODE_DISABLE_MOUSE | boolean | false | Disable TUI mouse capture |
MIMOCODE_DISABLE_DEFAULT_PLUGINS | boolean | false | Disable default plugins |
MIMOCODE_DISABLE_LSP_DOWNLOAD | boolean | false | Disable LSP server auto-download |
MIMOCODE_DISABLE_MODELS_FETCH | boolean | false | Disable fetching the model manifest from remote |
MIMOCODE_DISABLE_EMBEDDED_WEB_UI | boolean | false | Disable the built-in Web UI |
MIMOCODE_ENABLE_ANALYSIS | boolean | true | Telemetry switch (model_call / tool_call / agent_request), set false to turn off |
MIMOCODE_ENABLE_EXPERIMENTAL_MODELS | boolean | false | Enable experimental models |
MIMOCODE_ENABLE_EXA | boolean | false | Enable the Exa web search tool |
MIMOCODE_ENABLE_QUESTION_TOOL | boolean | false | Enable the question tool |
MIMOCODE_DISABLE_PROJECT_CONFIG | boolean | false | Forbid reading in-project .mimocode/ config |
MIMOCODE_DISABLE_GIT | boolean | false | Skip all git detection, treat the project as a non-git directory |
MIMOCODE_DISABLE_CHANNEL_DB | boolean | true | All channels share one mimocode.db; set false to restore per-channel isolation |
Control the mutual visibility between MiMo Code and the Claude Code ecosystem and third-party skills.
| Variable | Type | Default | Effect |
|---|---|---|---|
MIMOCODE_MIMO_ONLY | boolean | true | Master switch for pure-mimo mode: don't inherit .claude/, don't read provider env vars, default model falls back to mimo-auto |
MIMOCODE_DISABLE_PROVIDER_ENV | boolean | false | Disable provider env vars separately (implicitly on in mimo-only mode) |
MIMOCODE_DISABLE_CLAUDE_CODE | boolean | false | Explicitly disable .claude/ inheritance when mimo-only is off (prompt + skills, excluding MCP) |
MIMOCODE_DISABLE_CLAUDE_CODE_PROMPT | boolean | false | Disable ~/.claude/CLAUDE.md separately |
MIMOCODE_DISABLE_CLAUDE_CODE_SKILLS | boolean | false | Disable .claude/skills separately |
MIMOCODE_DISABLE_CLAUDE_CODE_MCP | boolean | false | Disable Claude Code MCP compatibility (still on by default in mimo-only mode) |
MIMOCODE_DISABLE_EXTERNAL_SKILLS | boolean | false | Disable all external skill sources at once |
MIMOCODE_DISABLE_CODEX_SKILLS | boolean | false | Disable codex skills separately |
MIMOCODE_DISABLE_OPENCODE_SKILLS | boolean | false | Disable opencode skills separately |
MIMOCODE_DISABLE_COMPOSE_SKILLS | boolean | false | Disable compose skills separately |
| Variable | Type | Default | Effect |
|---|---|---|---|
MIMOCODE_SERVER_PASSWORD | string | — | Enable basic auth for serve / web |
MIMOCODE_SERVER_USERNAME | string | mimocode | Basic auth username |
MIMOCODE_AUTH_CONTENT | string | — | Inline JSON credential content (for CI injection) |
MIMOCODE_CONSOLE_TOKEN | string | — | Console auth token |
MIMOCODE_WORKSPACE_ID | string | — | Workspace identifier |
MIMOCODE_CLIENT | string | cli | Client identifier (affects USER_AGENT and tool registration) |
The variables below enable features that may change or be removed without notice. MIMOCODE_EXPERIMENTAL=true turns on all experimental items at once.
| Variable | Type | Default | Effect |
|---|---|---|---|
MIMOCODE_EXPERIMENTAL | boolean | false | Enable all experimental features |
MIMOCODE_EXPERIMENTAL_ICON_DISCOVERY | boolean | false | Enable icon discovery |
MIMOCODE_EXPERIMENTAL_DISABLE_COPY_ON_SELECT | boolean | true on Win | Disable TUI copy-on-select |
MIMOCODE_EXPERIMENTAL_BASH_DEFAULT_TIMEOUT_MS | number | — | Default bash command timeout (ms) |
MIMOCODE_EXPERIMENTAL_OUTPUT_TOKEN_MAX | number | — | Max output tokens for LLM responses |
MIMOCODE_EXPERIMENTAL_FILEWATCHER | boolean | false | Enable whole-directory file watching |
MIMOCODE_EXPERIMENTAL_DISABLE_FILEWATCHER | boolean | false | Disable file watching |
MIMOCODE_EXPERIMENTAL_OXFMT | boolean | false | Enable the oxfmt formatter |
MIMOCODE_EXPERIMENTAL_LSP_TOOL | boolean | false | Enable the experimental LSP tool |
MIMOCODE_EXPERIMENTAL_LSP_TY | boolean | false | Enable TY LSP (Python) |
MIMOCODE_EXPERIMENTAL_PLAN_MODE | boolean | false | Enable Plan mode |
MIMOCODE_EXPERIMENTAL_MARKDOWN | boolean | true | Markdown rendering; set false to turn off |
MIMOCODE_EXPERIMENTAL_HTTPAPI | boolean | false | Enable the experimental HTTP API |
MIMOCODE_EXPERIMENTAL_WORKSPACES | boolean | false | Enable workspace support |
The variables below are mainly for performance diagnostics, build testing, and CI sandboxes, and are not recommended for regular use.
| Variable | Type | Default | Effect |
|---|---|---|---|
MIMOCODE_SHOW_TTFD | boolean | false | Show time-to-first-draw in the TUI |
MIMOCODE_AUTO_HEAP_SNAPSHOT | boolean | false | Auto-write a heap snapshot on startup |
MIMOCODE_SKIP_MIGRATIONS | boolean | false | Skip database migrations |
MIMOCODE_STRICT_CONFIG_DEPS | boolean | false | Strict config dependency mode |
MIMOCODE_FAST_BOOT | boolean | false | Fast boot (skip some sync checks) |
MIMOCODE_PLUGIN_META_FILE | string | — | Plugin metadata output file |
MIMOCODE_FAKE_VCS | string | — | Mock VCS provider, for testing only |
MIMOCODE_OUTPUT_LENGTH_CONTINUATION_LIMIT | number | 3 | Max continuations when output is too long |
MIMOCODE_INVALID_OUTPUT_CONTINUATION_LIMIT | number | 2 | Max continuations on invalid output |
Switch the profile root for isolated testing.
Temporarily enable auto-update (disabled by default).
Turn off telemetry reporting.
Inject config and credentials via inline JSON in CI.
Turn off mimo-only mode to inherit Claude Code prompts and skills.
Enable basic auth for serve.