Ollama keeps every pulled model in one folder, and on a small system drive that folder fills up fast. The Ollama FAQ lists the defaults — ~/.ollama/models on macOS, /usr/share/ollama/.ollama/models on Linux, and C:\Users\%username%\.ollama\models on Windows — and says that to use a different directory you set the OLLAMA_MODELS environment variable to the chosen directory.
Related guide: How to See Your Downloaded Ollama Models and Sizes
Set the variable before the server starts
The variable must be set before Ollama starts, because the server reads it at startup. On Windows, quit Ollama from the taskbar first, then set OLLAMA_MODELS as a user environment variable (the FAQ’s Windows steps: Settings, search for environment variables, edit the variable for your account) and start Ollama again from the Start menu. On Linux with the systemd service, use systemctl edit ollama.service and add an Environment="OLLAMA_MODELS=/path/to/models" line under [Service], then reload systemd and restart the service. On macOS, use launchctl setenv OLLAMA_MODELS /path/to/models and restart the Ollama application.
Move the models, then verify
Move the existing models folder contents to the new location (or leave them and re-pull). Then run ollama list: the models you moved should appear with their sizes. If the list is empty, the variable did not reach the server — the most common cause is setting it in a terminal while the server was started another way, for example as a service. Set it the same way the server is actually launched, and restart.
Expected result. We checked the Ollama FAQ for the default locations on all three platforms, the OLLAMA_MODELS instruction, and the per-platform environment-variable steps. We did not run this software ourselves for this guide, so no output here is a recorded result; steps marked UNTESTED were checked against the sources below, not run.
Limits
Ollama looks up models only in its own models directory, so two Ollama instances with different OLLAMA_MODELS settings have different model lists — a model pulled into one is invisible to the other. Do not point two running servers at the same folder. We did not move a models folder ourselves; the steps are from the FAQ, marked UNTESTED on this machine.
Sources
- Ollama FAQ — default model locations on macOS, Linux and Windows; set OLLAMA_MODELS to use a different directory; per-platform instructions for setting environment variables
- Ollama model-not-found decoder — OLLAMA_MODELS set for one instance and not another splits the model list; the Linux service and a hand-started server use different folders
Checked 2026-11-28.
