# Ollama vs LM Studio on Windows and Linux

Ollama or LM Studio? Compare the two free apps for local AI on Windows and Linux, with the app, the models, speed, the API, other devices and the licence.

2026-11-19


Ollama and LM Studio both run open-weight language models on your own device, both are free, and both run the GGUF model files of llama.cpp. They are made for different work. Ollama is a model server that you use mostly from the command line and from other programs, with a small chat app on Windows and macOS. LM Studio is a desktop app to find, try and serve models, with the same full interface on Windows, Linux and macOS.

This guide compares the two on Windows and Linux. Every fact comes from the projects' own pages, read on 19 November 2026, for Ollama 0.40.16 and LM Studio 0.4.28. The [sources](#sources) are at the end. Hearthscale, which publishes this guide, is a free app that works with both: see [Using both with Hearthscale](#both).

## TL;DR {#tldr}

- **Choose Ollama** for open-source software under the MIT licence, an install on Windows with no administrator rights, and one command, `ollama launch`, that sets up a coding tool such as Claude Code or Codex with your local models.
- **Choose LM Studio** for a full desktop app on Linux as well as on Windows, a search of Hugging Face inside the app, MCP servers in your chats, and API tokens that protect the server on your network.

For speed, neither is faster in every case. See [Which is faster?](#speed)

## At a glance {#table}

|                 | Ollama                                                                        | LM Studio                                                                                      |
| --------------- | ----------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------- |
| Desktop app     | Windows and macOS                                                             | Windows, Linux and macOS                                                                       |
| On Linux        | The command line and the API                                                  | The desktop app, as an AppImage or a `.deb` package                                            |
| Systems         | Windows 10 22H2 or newer; macOS 14 or newer; Linux on x64 and ARM64           | Windows on x64 (with AVX2) and Arm; macOS 14 or newer on Apple silicon; Linux on x64 and ARM64 |
| Licence         | Open source, MIT                                                              | Proprietary, free at home and at work; the `lms` command is MIT                                |
| Models from     | The Ollama library, and GGUF files on Hugging Face                            | Any supported model on Hugging Face, searched in the app                                       |
| Model files     | Files named by their SHA-256 hash                                             | `.gguf` files in a folder for each publisher and model                                         |
| Engines         | llama.cpp, Ollama's own engine, MLX on Apple silicon                          | llama.cpp, MLX on Apple silicon                                                                |
| Graphics cards  | NVIDIA (CUDA), AMD (ROCm), others through Vulkan                              | NVIDIA (CUDA), AMD (ROCm on Linux), others through Vulkan                                      |
| API             | Port 11434: Ollama's API, OpenAI-compatible, part of Anthropic's Messages API | Port 1234: LM Studio's REST API, OpenAI-compatible, Anthropic's Messages API                   |
| Other devices   | Set `OLLAMA_HOST`; the local API has no authentication                        | Serve on Local Network with optional API tokens; LM Link with an account                       |
| Your documents  | Drag text and PDF files into the app                                          | Attach `.docx`, `.pdf` and `.txt` files to a chat                                              |
| Cloud models    | Ollama's cloud: a price per token, or plans from 20 USD a month               | US-hosted models with Bionic+, for 20 USD a month                                              |
| Version checked | 0.40.16, 9 November 2026                                                      | 0.4.28, 31 October 2026                                                                        |

## The desktop app {#app}

**Ollama's app** runs on Windows and macOS. In it, you download models, chat with them, and drag text and PDF files into a conversation. Ollama installs with no administrator rights, in your home folder. Download `OllamaSetup.exe`, or run this in PowerShell:

```powershell
irm https://ollama.com/install.ps1 | iex
```

On Linux, Ollama has no desktop app. Install it with one command, then use it from the terminal or through its API:

```sh
curl -fsSL https://ollama.com/install.sh | sh
```

**LM Studio** is the same desktop app on Windows, Linux and macOS. On Linux, it comes as an AppImage or a `.deb` package. In the app, you search for models, download them, chat, attach documents, and start the local server. LM Studio is also an MCP host: since version 0.3.17, you can add MCP servers and use their tools with your local models. On x64 Windows, LM Studio needs a processor with AVX2, and its system requirements recommend 16 GB of system memory and 4 GB of graphics memory.

## Finding and storing models {#models}

**In Ollama**, you download models from the Ollama library by name, such as `ollama pull gemma4`. You can also run a GGUF file from Hugging Face by its repository, with `ollama run hf.co/{username}/{repository}`. Ollama then takes the Q4_K_M quantization when the repository has one.

Ollama keeps its models in `.ollama\models` in your user folder on Windows, and in `/usr/share/ollama/.ollama/models` on Linux. Inside, each file is named by its SHA-256 hash, not by the model's name. To keep the models on another drive, set `OLLAMA_MODELS` to the folder you want.

**In LM Studio**, you search Hugging Face from inside the app, by a keyword, by `user/model`, or by a whole Hugging Face address. To download from the terminal, use `lms get`. LM Studio keeps each model as a plain `.gguf` file in `~/.lmstudio/models`, in a folder for its publisher and one for the model. To use another folder, change it in **My Models**.

### Can Ollama and LM Studio share model files? {#share}

Not directly. To add a GGUF file to Ollama, write a Modelfile with the line `FROM /path/to/file.gguf` and run `ollama create`. To add one to LM Studio, run `lms import`, which moves the file unless you add `--copy`, `--hard-link` or `--symbolic-link`. Hearthscale Server runs the files of both apps where they are, with no copy: see [below](#both).

## Which is faster? {#speed}

For GGUF models, Ollama and LM Studio both run llama.cpp. On the same device, the speed of a model depends more on four settings than on the app:

- **How much of the model is on the graphics card.** Layers in system memory are slower than layers in graphics memory. In Ollama, `ollama ps` shows the split under **PROCESSOR**, such as `100% GPU`.
- **The context length.** Ollama sets the context from the graphics memory: 4k tokens below 24 GiB, 32k tokens from 24 to 48 GiB, and 256k tokens from 48 GiB. A small context leaves more memory for the model, so a short test can look fast. Ollama's own guide says that agents, web search and coding tools need at least 64,000 tokens.
- **The build of the runtime.** CUDA on NVIDIA, and ROCm or Vulkan on AMD and other graphics cards. Each app brings its own build of llama.cpp. In LM Studio, you manage the runtime packs with **Ctrl+Shift+R** on Windows and Linux. Builds differ in the models and graphics cards they support well, so update both apps before you compare them.
- **The quantization.** A Q4_K_M file is smaller than the Q8_0 file of the same model, and usually faster. See [GGUF quantization explained](/blog/gguf-quantization).

To compare the two on your device, load the same model at the same quantization, set the same context length, keep the whole model on the graphics card, and send the same prompt. Then compare the tokens per second of each reply. On a Mac with Apple silicon, both also run models with MLX, Apple's framework for machine learning. For the speeds of NVIDIA graphics cards with CUDA and Vulkan, see [Local LLMs on NVIDIA GPUs](/blog/local-ai-nvidia-gpu); for AMD graphics cards with Vulkan and ROCm, see [Run local AI on an AMD GPU](/blog/local-ai-amd-gpu); for Intel Arc, see [Run local AI on an Intel Arc GPU](/blog/local-ai-intel-gpu); for processors with no graphics card, see [Run a local LLM without a GPU](/blog/local-ai-without-gpu).

## Coding tools and agents {#coding}

**In Ollama**, one command sets up a coding tool: `ollama launch` configures and starts Claude Code, Codex, OpenCode and other tools with Ollama's models, and assistants such as OpenClaw and Hermes Agent:

```sh
ollama launch claude --model qwen3.5
```

Ollama's API answers on port 11434 in Ollama's own format, as OpenAI's Chat Completions and Responses APIs, and as a part of Anthropic's Messages API.

**LM Studio** serves the same kinds of API on port 1234: its own REST API, OpenAI-compatible routes with Responses, and Anthropic's Messages API at `/v1/messages`. To use Claude Code, set `ANTHROPIC_BASE_URL` to `http://localhost:1234`. On a server with no desktop, run `llmster`, LM Studio's headless daemon, with `lms daemon up` and `lms server start`.

With either app, set the context to at least 64,000 tokens for a coding agent, as Ollama's guide advises, and choose a model that your memory holds with that context. [Best local LLM for coding](/blog/local-llm-for-coding) compares the models and the memory of their context.

## Using your models from other devices {#other-devices}

**Ollama** listens only at `127.0.0.1` until you set the `OLLAMA_HOST` environment variable. Its local API has no authentication, so any device that reaches the port can use your models.

**LM Studio** has **Serve on Local Network**, which makes the server listen on your network. By default, it accepts requests with no token. Since version 0.4.0, you can require an API token for every request. LM Link, a preview, connects your devices through a private network built on Tailscale. It needs an LM Studio account, and the free plan covers up to 5 devices.

## Licence and commercial use {#licence}

Ollama is open source under the MIT licence. LM Studio is proprietary, and free at home and at work since 8 July 2025. Its terms allow personal use and internal business use. LM Studio's `lms` command and its SDKs are MIT-licensed.

## Using both with Hearthscale {#both}

[Hearthscale](/) is a free app for Windows and Linux that runs AI models on your own device. It works with Ollama and LM Studio:

- **Both as providers.** Start Ollama or LM Studio's server, and Hearthscale lists it under **Settings → Providers → Runtimes on this device**. Their models then show in the model picker of Ash, the assistant, and of other apps. Hearthscale doesn't start them or manage their models.
- **Their model files, where they are.** Hearthscale Server finds the language models that Ollama and LM Studio keep on your device, and those of Msty, Jan and GPT4All. In the Server, choose **Import model**, then **Use in place** beside a model under **Models in other apps**. Nothing is copied, the other app doesn't need to run, and its files are never changed or deleted. See [Import a model file](/docs/server/models/import#in-place).
- **More than chat.** The same Server runs models for pictures, speech and music, for [Image studio](/ai-image-generator), [Dictation](/dictation), [Meeting notes](/ai-meeting-notes) and [Music studio](/ai-music-generator).
- **Your other devices.** Every device with Hearthscale can use the Server's models, end-to-end encrypted, with no port to open. You allow each new device on the Server. See [Hearthscale Server](/server).

Hearthscale is not open source, and it doesn't run on macOS yet. For more on each comparison, see [Hearthscale and Ollama](/compare/ollama) and [Hearthscale and LM Studio](/compare/lm-studio). New to local AI? Start with [How to run AI locally on Windows and Linux](/blog/run-ai-locally).

[Download Hearthscale](/download) for Windows or Linux. Hearthscale is free, and you need no account.

## Sources {#sources}

Read on 19 November 2026.

- Ollama: [Windows](https://docs.ollama.com/windows), [Linux](https://docs.ollama.com/linux), [macOS](https://docs.ollama.com/macos), [the new app](https://ollama.com/blog/new-app), [licence](https://github.com/ollama/ollama/blob/main/LICENSE), [FAQ](https://docs.ollama.com/faq), [hardware support](https://docs.ollama.com/gpu), [context length](https://docs.ollama.com/context-length), [import](https://docs.ollama.com/import), [Modelfile](https://docs.ollama.com/modelfile), [CLI](https://docs.ollama.com/cli), [integrations](https://docs.ollama.com/integrations), [OpenAI compatibility](https://docs.ollama.com/api/openai-compatibility), [Anthropic compatibility](https://docs.ollama.com/api/anthropic-compatibility), [authentication](https://docs.ollama.com/api/authentication), [MLX on Apple silicon](https://github.com/ollama/ollama/releases/tag/v0.40.0), [GGUF through llama.cpp](https://ollama.com/blog/improved-performance-and-model-support-with-gguf), [pricing](https://ollama.com/pricing), [releases](https://github.com/ollama/ollama/releases), and Hugging Face's guide [Use Ollama with any GGUF model](https://huggingface.co/docs/hub/ollama).
- LM Studio: [system requirements](https://lmstudio.ai/docs/app/system-requirements), [download](https://lmstudio.ai/download), [docs](https://lmstudio.ai/docs/app), [download a model](https://lmstudio.ai/docs/app/basics/download-model), [chat with documents](https://lmstudio.ai/docs/app/basics/rag), [MCP](https://lmstudio.ai/docs/app/mcp), [`lms import`](https://lmstudio.ai/docs/cli/local-models/import), [OpenAI compatibility](https://lmstudio.ai/docs/developer/openai-compat), [Anthropic compatibility](https://lmstudio.ai/docs/developer/anthropic-compat), [REST API](https://lmstudio.ai/docs/developer/rest), [headless](https://lmstudio.ai/docs/developer/core/headless), [Serve on Local Network](https://lmstudio.ai/docs/developer/core/server/serve-on-network), [authentication](https://lmstudio.ai/docs/developer/core/authentication), [LM Link](https://lmstudio.ai/link), [LM Link setup](https://lmstudio.ai/docs/lmlink/basics), [pricing](https://lmstudio.ai/pricing), [free for work](https://lmstudio.ai/blog/free-for-work), [terms](https://lmstudio.ai/app-terms), [ROCm on Linux](https://lmstudio.ai/blog/lmstudio-v0.3.19), [changelog](https://lmstudio.ai/changelog/lmstudio).
