Stopping a running Ollama model unloads it from memory without deleting the downloaded model. It is useful after a large model test, before changing memory-related settings, or when another workload needs GPU or system RAM.
Use ollama ps to identify loaded models and ollama stop to unload the target name. The installed model remains visible in ollama list after it leaves the process list.
If the model reloads immediately, another client may still be sending requests. Stop the client or reduce keep-alive behavior before assuming ollama stop failed.
Related: How to list running Ollama models
Related: How to set Ollama model keep alive
Related: How to run a model in Ollama
$ ollama ps NAME ID SIZE PROCESSOR CONTEXT UNTIL gpt-oss:20b 17052f91a42e 12 GB 100% GPU 131072 4 minutes from now
$ ollama stop gpt-oss:20b
$ ollama ps
NAME ID SIZE PROCESSOR CONTEXT UNTIL
$ ollama list
NAME ID SIZE
gpt-oss:20b 17052f91a42e 13 GB
$ curl -s http://localhost:11434/api/generate -d '{"model":"gpt-oss:20b","prompt":"OK","stream":false,"keep_alive":0}' {"done":true}
Related: How to set Ollama model keep alive