docs/dev-tools/backend_architecture.md
Understanding how mise's backend system works can help you choose the right backend for your tools and troubleshoot issues when they arise. Most users don't need to explicitly choose backends since the mise registry defines smart defaults, but understanding the system helps when you need specific tools or want to optimize performance.
Backends are mise's way of supporting different tool installation methods. Each backend knows how to:
Think of backends as "adapters" that let mise work with different package managers and installation systems.
All backends implement a common interface (called a "trait" in Rust), which means they all provide the same basic functionality:
pub trait Backend {
async fn list_remote_versions(&self) -> Result<Vec<String>>;
async fn install_version(&self, ctx: &InstallContext, tv: &ToolVersion) -> Result<()>;
async fn uninstall_version(&self, tv: &ToolVersion) -> Result<()>;
// ... other methods
}
This design allows mise to treat all backends uniformly while each backend handles the specifics of its installation method.
Built directly into mise, written in Rust for performance and reliability:
::: info Core tools like Node.js and Java are implemented as backends even though they represent single tools. This consistent backend architecture allows mise to handle all tools uniformly, whether they're complex ecosystems or individual tools. :::
Leverage existing language ecosystems:
npm:prettier, npm:typescript)pipx:black, pipx:poetry)cargo:ripgrep, cargo:fd-find)gem:bundler, gem:rails)go:github.com/golangci/golangci-lint/cmd/golangci-lint)Registry-based package manager with strong security features:
aqua:golangci/golangci-lint::: warning The ubi backend is deprecated. Use the github backend instead. :::
Zero-configuration installer that works with any GitHub/GitLab repository following standard conventions:
ubi:BurntSushi/ripgrep → migrate to github:BurntSushi/ripgrepSupport for external plugin ecosystems:
my-tool) - a superset of vfox plugins functionalityasdf:postgres, asdf:redis) - generally Linux/macOS onlyplugin:tool format (my-plugin:some-tool) - enables private/custom tools with backend methodsWhen you specify a tool, mise determines the backend using this priority:
mise use aqua:golangci/golangci-lintMISE_BACKENDS_<TOOL> (see below)mise use golangci-lint → checks registry for default backendmise use node → uses built-in core backendThe mise registry defines a priority order for which backend to use for each tool, so typically end-users don't need to know which backend to choose unless they want tools not available in the registry or want to override the default selection.
You can override the backend for any tool using the MISE_BACKENDS_<TOOL> environment variable pattern. The tool name is converted to SHOUTY_SNAKE_CASE (uppercase with underscores replacing hyphens).
# Use vfox backend for php
export MISE_BACKENDS_PHP='vfox:mise-plugins/vfox-php'
mise install php@latest
The registry (mise registry) maps short names to full backend specifications with a preferred priority order:
# ~/.config/mise/config.toml
[tool_alias]
go = "core:go" # Use core backend
terraform = "aqua:hashicorp/terraform" # Use aqua backend
| Feature | Core | npm/pipx/cargo | aqua | ubi | Backend Plugins | Tool Plugins (vfox) | asdf Plugins (legacy) |
|---|---|---|---|---|---|---|---|
| Speed | ✅ | ⚠️ | ✅ | ✅ | ⚠️ | ⚠️ | ⚠️ |
| Security | ✅ | ⚠️ | ✅ | ⚠️ | ⚠️ | ⚠️ | ⚠️ |
| Windows Support | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ❌ |
| Env Var Support | ✅ | ❌ | ❌ | ❌ | ✅ | ✅ | ✅ |
| Custom Scripts | ✅ | ❌ | ❌ | ❌ | ✅ | ✅ | ✅ |
| Built-in Modules | ✅ | ❌ | ❌ | ❌ | ✅ | ✅ | ❌ |
| Security Attestations | ❌ | ❌ | ✅ | ❌ | ✅ | ✅ | ❌ |
| Multi-tool Plugins | ❌ | ❌ | ❌ | ❌ | ✅ | ❌ | ❌ |
| Progress/Logging | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ❌ |
Core tools should generally always be used when available, as they provide the best performance and integration with mise.
::: info
The ubi backend still works but is deprecated in favor of github. Replace ubi:owner/repo with github:owner/repo.
:::
plugin:tool format for flexibilityJAVA_HOME, GOROOT, etc.)JAVA_HOME, GOROOT, etc.)Some backends have dependencies on others:
graph TD
A[npm backend] --> B[Node.js]
C[pipx backend] --> D[pipx]
E[cargo backend] --> F[Rust]
G[gem backend] --> H[Ruby]
mise automatically handles these dependencies, installing Node.js before npm tools, pipx before pipx tools, etc.
# ~/.config/mise/config.toml
[settings]
disable_backends = ["asdf", "vfox"] # Don't use these backends
# mise.toml
[tools]
"core:node" = "20" # Explicitly use core backend
"aqua:yarn" = "latest" # Use aqua backend instead of default (vfox)
Some backends support additional configuration:
# mise.toml
[tools]
python = { version = "3.12", virtualenv = ".venv" } # Core backend options
black = { version = "latest", python = "3.12" } # pipx backend options
mise doctor # Check backend configuration
mise tool python # See which backend is used for a tool
mise config get tools # Verify tool configurations