How to Free Up Inactive (Blue) Memory in Mac OS X

Want to turn Activity Monitor’s “blue” (inactive) memory to “green” (free) on your Mac without closing any programs?

Run Terminal and type:

  $ purge

My memory went from  to  the last time I did this. Not too shabby. (Why did it also clear up some Active Memory? I have no idea.)

That’s all you have to do. It can take up to a minute. While purge is running your system will be slow. After that, with all that free memory, it’ll be zippier than before.

Don’t listen to all the remarkably obnoxious fanboys or official Apple support pages telling you just to leave Inactive Memory alone because it will be freed up quickly if it is needed, or that the system knows better than you do when to free memory. Trust your experience. In my experience it will not and it does not. 

Here is the purge man page:

PURGE(8)                  BSD System Manager's Manual                 PURGE(8)

     purge -- force disk cache to be purged (flushed and emptied)


     Purge can be used to approximate initial boot conditions with a cold disk buffer
     cache for performance analysis. It does not affect anonymous memory that has been
     allocated through malloc, vm_allocate, etc.

     sync(8), malloc(3)

5 thoughts on “How to Free Up Inactive (Blue) Memory in Mac OS X”

  1. Wow! That was impressive – it freed up a little over 2GB!

    I’ve never heard of that command before now. And now I have. 🙂

  2. I have read this SO MANY PLACES, but this command does nothing on my computer. it says the command is not recognized, any ideas?

  3. Anna –

    Several places mention that “Developer Tools” must be installed to have that command installed on the system. That’s one approach.

    Another approach is to get an app from the app store to take care of it. A couple of examples are “MenuBar Stats” and “FreeMemory” … low cost or free.

    Brian –

    Thanks. Very useful article.

Leave a Reply

Your email address will not be published. Required fields are marked *

Feel free to use <a>, <b>, <i>, <strong>, <em>, <strike>, <code>.

Code blocks:
[code language="ruby/javascript/html/css/sass/bash"]