Setup guide - From Ollama and Zed docs
Use Ollama in Zed
Zed has a native Ollama LLM provider that auto-discovers pulled models from http://localhost:11434; optional settings.json control the API URL, model list and context window.
Last verified 5 steps3 official sources
Steps
- Step 1.
Pull a model and make sure the Ollama server is running.
Terminalollama pull mistral ollama serve - Step 2.
In Zed, click the star icon in the bottom-right corner, select Configure, choose Ollama under LLM Providers, confirm the Host URL is
http://localhost:11434, click Connect, then select a model under Ollama. - Step 3.
Optional: disable autodiscovery and list models yourself in settings.
JSON{ "language_models": { "ollama": { "api_url": "http://localhost:11434", "auto_discover": false, "available_models": [ { "name": "qwen2.5-coder", "display_name": "qwen 2.5 coder", "max_tokens": 32768, "supports_tools": true, "supports_thinking": true, "supports_images": true } ] } } } - Step 4.
Set a context length for all Ollama models (Zed defaults to 4096 via num_ctx).
JSON{ "language_models": { "ollama": { "context_window": 8192 } } } - Step 5.
ollama.com cloud: create an API key on ollama.com, open the star icon > Configure > Ollama and set the API URL to https://ollama.com. Zed also reads OLLAMA_API_KEY.
Caveats
- Zed's default Ollama context is 4096 tokens, which is small for agent work; raise context_window or per-model max_tokens.
- Zed's Ollama provider applies to the Zed Agent, Inline Assistant and similar Zed features, not to External Agents or Terminal Threads.
- Model ids shown are the examples from Zed's docs; any pulled Ollama model is auto-discovered.
More setup guides
Same tool, other providers
Related reading
- Ollama Decision Models: Run Nimble Locally with --askOllama 0.40.4 runs decision models locally: ollama run nimble --ask answers yes/no, label and score questions with probabilities. Commands and limits.
- Ollama 0.40 on Mac: MLX by Default, Disk Space DoubledOllama 0.40 runs supported models on MLX on Apple Silicon and keeps a backup copy of each model you load. What it costs in disk, what is fixed, and the cleanup.
- GitHub Copilot CLI With Ollama: Local Models and the New SandboxCopilot CLI 1.0.94 finds local Ollama models from /model and ships an OS-level sandbox. Setup, the 4k context trap, and why local is not offline.
- Hermes Agent Guide (2026): What It Is, Local Setup With Ollama, Skills, and Hermes vs OpenClawHermes Agent is Nous Research's open-source, self-improving AI agent. Run it locally with Ollama, see how its skills system works, and compare it with OpenClaw.
- What Is OpenClaw? Setup, Skills, MCP Server, Claude Code, and Ollama (2026 Guide)What is OpenClaw? A self-hosted personal AI agent you reach through chat apps. Install, skills and ClawHub, its MCP server, Claude Code use, and Ollama models.
- GitHub Copilot for JetBrains Gains Persistent Memory and Ollama BYOKGitHub Copilot for JetBrains adds memory across chat sessions, Ollama as a BYOK provider, and enterprise settings for MCP access. What each feature does.
FAQ
How do I use Ollama in Zed?
Zed has a native Ollama LLM provider that auto-discovers pulled models from http://localhost:11434; optional settings.json control the API URL, model list and context window.
Which Ollama model ids work in Zed?
The official docs read for this guide list mistral and qwen2.5-coder. Requests go to http://localhost:11434.
Is this an official Ollama and Zed setup?
The steps draw on both Ollama's and Zed's docs. It was last checked against 3 official pages on October 17, 2026.
Sources
Last verified against 3 official pages.
- docs.ollama.comhttps://docs.ollama.com/integrations/zed
- raw.githubusercontent.comhttps://raw.githubusercontent.com/ollama/ollama/main/docs/integrations/zed.mdx
- raw.githubusercontent.comhttps://raw.githubusercontent.com/zed-industries/zed/main/docs/src/ai/use-a-local-model.md
Newsletter
New models, set up the day they ship
One email per week. New model releases, the coding tools that support them and how to wire them up.