Skip to main content
Watch: I Built an AI App Without Leaving Databricks

Setup guide - From Ollama and Roo Code docs

Use Ollama in Roo Code

Roo Code has a native Ollama API provider; set the provider to Ollama, keep the default base URL http://localhost:11434, and enter an Ollama model id.

Last verified 6 steps3 official sources

Steps

  1. Step 1.

    Install Roo Code from the VS Code Marketplace, open it, and click the gear icon at the top right to open Provider Settings.

  2. Step 2.

    Set API Provider to Ollama.

  3. Step 3.

    (Optional) Update Base URL if Ollama runs remotely. The default is http://localhost:11434.

  4. Step 4.

    Enter a valid Model ID, for example qwen3 or qwen3-coder:480b-cloud.

  5. Step 5.

    Adjust the Context Window to at least 32K tokens for coding tasks. Roo Code's docs show how to bake the context into an Ollama model.

    Terminal
    ollama run qwen2.5-coder:32b
    /set parameter num_ctx 32768
    /save your_model_name
  6. Step 6.

    ollama.com cloud: create an API key at https://ollama.com/settings/keys, enable Use custom base URL and set it to https://ollama.com, enter your Ollama API Key, then select a model.

Caveats

  • Roo Code's docs say it defers to the Modelfile's num_ctx setting by default, so context is set in Ollama rather than Roo.
  • Ollama's page names the Context Window setting in Roo; Roo's page instead recommends configuring num_ctx in an Ollama Modelfile. Both are documented.
  • The qwen2.5-coder:32b example comes from Roo Code's docs; Ollama's page uses qwen3 and qwen3-coder:480b-cloud.

FAQ

How do I use Ollama in Roo Code?

Roo Code has a native Ollama API provider; set the provider to Ollama, keep the default base URL http://localhost:11434, and enter an Ollama model id.

Which Ollama model ids work in Roo Code?

The official docs read for this guide list qwen3, qwen3-coder:480b-cloud and qwen2.5-coder:32b. Requests go to http://localhost:11434.

Is this an official Ollama and Roo Code setup?

The steps draw on both Ollama's and Roo Code's docs. It was last checked against 3 official pages on October 17, 2026.

Sources

Last verified against 3 official pages.

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.