Mac Won’t Sleep? Here’s How to Find Out Why And Fix It

Jul 11, 2012 - 24 Comments

Find why a Mac won't go to sleep

On the rare occasion that you go to put a Mac to sleep and, well, it won’t sleep, there’s an easy to way to find out what the holdup is. Though this is a somewhat technical approach, it should give a good starting point to anyone who’s confused as to why something like automatic sleep isn’t taking effect, and hopefully provide a quick resolution to the problem.

Determining the Cause of Sleep Prevention in Mac OS X with the Command Line

This works to determine both why a Mac won’t sleep and why a Mac display is not sleeping:

  • Launch Terminal from /Applications/Utilities/ and type the following command:
  • pmset -g assertions

  • Look through the reported assertion list for items with a “1” next to their name to find what’s keeping the Mac awake

For example, if you see something like the following:

$ pmset -g assertions
7/11/12 10:45:33 PM PDT
Assertion status system-wide:
PreventUserIdleDisplaySleep 0
CPUBoundAssertion 0
DisableInflow 0
ChargeInhibit 0
PreventSystemSleep 0
PreventUserIdleSystemSleep 1
NoIdleSleepAssertion 1
ExternalMedia 0
DisableLowPowerBatteryWarnings 0
EnableIdleSleep 1
NoRealPowerSources_debug 0
UserIsActive 0
ApplePushServiceTask 0

Listed by owning process:
pid 1827: [0x000000bb012c01f1] PreventUserIdleSystemSleep named: "'AppleHDAEngineOutput:1B,0,1,1:0'.noidlesleep"

You’ll notice the “sleep when idle” feature is disabled, but what you really want to pay attention to is the lower portion of the list where the “Listed by owning process” report shows as the reason that PreventUserIdleSystemSleep is enabled. Why is that? Because iTunes is running and playing music, meaning the computer isn’t idle.

If you’re having persistent problems with sleep and the above tip doesn’t give you any clue as to where to begin, sleep issues relating to hardware and power management quirks can often be fixed with an SMC reset. On the other side of the fence, another command line tip shows us how to find out why a Mac woke up from sleep. Sometimes the same thing preventing a Mac from sleeping is responsible from waking it up too, like Time Machine and schedule backups.

This is a handy tip from Lifehacker who also provides a similar tip for Windows computers. Don’t miss Apple’s article on the topic too for some additional help.


Related articles:

Posted by: William Pearson in Mac OS, Tips & Tricks, Troubleshooting


» Comments RSS Feed

  1. Dave says:

    I have the same computer, same problem. When I was running Yosemite I could open terminal and enter the command “sudo killall configd” which seemed to work, but not on High Sierra

  2. Gary says:

    Hopefully someone has an answer to this one… I have 2009 Mac Pro and when I log off, and then click “sleep” the system seems to go to sleep, but despite the screen staying blank, it sounds like someone is constantly waking and then sleeping the system.

  3. Thanks says:

    Thanks for this useful command, greatly appreciated.

  4. Nicholas Wade says:


    After nearly going completely crazy trying to disable everything, it turned out to be the Common Unix Printing System (thanks to

    Turn off the CUPS from the command line:

    sudo launchctl unload -w /System/Library/LaunchDaemons/org.cups.cupsd.plist

    You can re-enable it with the following:

    sudo launchctl load -w /System/Library/LaunchDaemons/org.cups.cupsd.plist

    You can test to see if it’s running with the following command:

    sudo launchctl list | grep cupsd

  5. ya boi says:

    I even force quit apple music and I put the command in again and it still shows “”

  6. Diego says:

    OMG I had I pending print job from like 2 years ago from a printer I don’t have anymore. I deleted it and now my mac can sleep again! :D

    Thanks Bruno!

  7. Heather says:

    Thanks Bruno – after a lot of time spent looking into techie solutions, it turned out that a job hadn’t printed and was just sitting there in my Epson printer utility.

  8. Diana says:

    Jan D, you’re a life saver! My problem was also the HP printer queue. Thanks!

  9. Jan D says:

    After trying everything i could find on the web, i figured out that it was a page in the (HP) printer queue that was keeping my Mac from sleeping for days. Turned on the printer, forced the page to print and my Mac is now FINALLY going back to sleep.

    There was no indication of this in the Activity Monitor nor the “pmset -g assertions” command that pointed to anything printer related. Hope this helps someone !

  10. Francis says:

    Thanks! You solve my problem.

  11. Raj says:

    i discovered it was my internet connection sharing that was preventing sleep mode.

  12. jfsjfs says:

    New iMac 2012 would not stay asleep. Found out it was the HP USB keyboard keeping it awake. Switched keyboard and the problem went away. Hope this helps someone.


  13. Max says:

    This one is the hero of the day, thanx a lot!
    internet sharing was my problem. Disabled it from preferences and voilá no problems to sleep. I think it was related to i share my printer by wifi, but at least now i know what to do.
    Happy new year and thanx a lot for this article!

  14. Somian says:

    Ok, now I know that ExternalMedia is preventing sleep but how can I fix it? Shouldn’t it be possible to put a mac to sleep a mac with a HDD connected?

  15. Bruno Pascoal says:

    I was having issues with my Macbook Pro not sleeping at all (not with the lid closed nor by selecting “Sleep” in the Apple menu) and resetting the SMC didn’t help. The above tip didn’t show me what was cauing it.

    After some internet searching I learned that pending printing jobs are commonly the cause. Especially when you have added online printers (in my case it was a wireless HP printer AND a Xerox network printer). If you go to your printer list you’ll eventually find one that is “in use” even if it was the shared wireless printer in the hotel lobby on your last vacation. Simply delete any pending jobs or erase the printer altogether.

    Worked for me!

    • John says:

      Thanks Bruno, I was getting the same problem and checked my printer, its low on ink and had some printing pending. Cancelled it now the sleep function works as it should.

    • Steve says:

      Thanks, Bruno.

      That’s exactly the info I needed!

      It works now.

    • Maverick says:

      Thanks Bruno, so simple and finally sorted the problem.

    • Milo says:

      Thanks, this great tip also solved my problem.
      I have two printers connected and the oldest one i don’t use anymore. That printer had one job in queue and kept like you said my mac from going into sleep mode.
      problem solved.

    • Alfdrummer says:

      Bruno, you rock my good sir. I simply deleted a pending printing job and my computer went to sleep like a baby.

      Thanks a million

    • Mathias says:

      Thanks Bruno, this worked for me as well!

      Not going to sleep neither automatically nor the forced sleep made me crazy – I even updated to Sierra ;-)
      Kept me busy way too long to find the reason!
      Checked all printers and there it was: an old printing job for a switched off printer (waiting to replace one ink tank -therefore not in use). Deleted that job and used the forced sleep and the Mac mini actually went to sleep right away.

      I had this problem so many times on different Macs in the past and never found out what actually resolved the problem.

      I hope I do remember it for the next time!

      Cheers from Germany,

    • Denis de Castro says:

      Just another thank-you to Bruno Pascoal. After much searching, thanks!

    • Diego says:

      OMG I had I pending print job from like 2 years ago from a printer I don’t have anymore. I deleted it and now my mac can sleep again! :D

      Thanks Bruno!

  16. Dave says:

    I’ve found a little over a year ago that the voice commands / speech recognition prevents my iMac and macbook from going to sleep if it’s used even once. I opened a ticket with Mac who acknowledged the problem but wouldn’t commit to a fix. I have to recycle speakable items.

    Plus speech recognition has a huge memory leak, about 750m / day.

    This is a pretty interesting find.

Leave a Reply


Shop on and help support OSXDaily!

Subscribe to OSXDaily

Subscribe to RSS Subscribe to Twitter Feed Follow on Facebook Subscribe to eMail Updates

Tips & Tricks


iPhone / iPad



Shop on Amazon to help support this site