---
title: "Unload Ollama and Docker Desktop memory on a Mac · MacMelon"
description: "Ollama keeps models loaded after a request, and Docker Desktop keeps a virtual machine running. Unload models and quit Docker Desktop when you are done."
url: "https://macmelon.com/use-cases/get-memory-back-from-ollama-and-docker"
---

# Get memory back from local AI models and Docker Desktop

A loaded Ollama model and Docker Desktop's virtual machine can hold a lot of memory while you do something else. Unload or quit them when you are done.

Ollama keeps a model in memory for a while after each request, so the next one is fast. On a Mac, where memory is shared with everything else, a large model left loaded can push other apps into [swap](https://macmelon.com/glossary/swap-memory). Docker Desktop runs a virtual machine that can keep holding memory even when no containers need it.

[Sentinely](https://macmelon.com/apps/sentinely) shows which Ollama models are loaded and how much Docker Desktop is holding. Unloading uses Ollama's own unload, and the next request loads the model again. Quitting Docker Desktop stops its containers, so Sentinely asks you to confirm.

## Steps

1.  ### Check what is loaded

    Without Sentinely, run ollama ps in Terminal to list loaded models. Sentinely shows the same models in its findings, with the memory they hold.

2.  ### Unload models you are not using

    Sentinely asks Ollama to unload the models, the same as a request with keep\_alive set to 0. You can also run ollama stop with the model name. Finish running requests first.

3.  ### Quit Docker Desktop when no containers need it

    If Docker Desktop is holding memory, Sentinely offers to quit it. Running containers stop. Open Docker Desktop again when you need it.

4.  ### Make it stick

    To keep Ollama from holding models as long, set its keep-alive time. For Docker Desktop, the Resources settings limit how much memory its virtual machine can use. With Pro, Autopilot can unload idle Ollama models when memory gets tight.

## Before you start

-   Sentinely cannot tell whether another app is in the middle of a request to Ollama. Finish running requests before you unload.
-   Quitting Docker Desktop stops every running container. Check that nothing you need is running.

## Questions

Does unloading delete the model?

No. The model stays on disk. Unloading only frees the memory it was using, and the next request loads it again.

Will Sentinely quit Docker Desktop on its own?

No. Quitting Docker Desktop always needs your confirmation, and Autopilot never quits apps.

## Apps

[No more Force Quit in the middle of a build. ### Sentinely](https://macmelon.com/apps/sentinely)

## Related guides

[### How to find what's slowing down your Mac](https://macmelon.com/guides/how-to-find-what-is-slowing-down-your-mac)

## Related use cases

[### Stop AI-tool helpers left running after you close your editor](https://macmelon.com/use-cases/stop-leftover-ai-helpers-and-mcp-servers)[### Find out why your Mac is slow](https://macmelon.com/use-cases/find-out-why-your-mac-is-slow)

## Related terms

[How hard macOS is working to make room in memory. The signal that a Mac is actually short on memory, not just using it. ### Memory pressure](https://macmelon.com/glossary/memory-pressure)[Memory macOS has moved from RAM to the startup disk because RAM ran short. ### Swap](https://macmelon.com/glossary/swap-memory)[The memory macOS charges to a process, including memory it has compressed. Sentinely's unit for estimates and receipts. ### Memory footprint](https://macmelon.com/glossary/memory-footprint)[Watched-folder cleanup in Disk Housekeeper, still behind a preview. In Sentinely, the memory fixes you have approved. ### Autopilot](https://macmelon.com/glossary/autopilot)
