How can I stop my iMac trying to log me off when I leave it unattended for a while?
Many of the features in a modern operating system seem to be designed for a workplace where there are lots of cubicles and people roaming around, causing mischief unless prevented. Not that I have anything against the security of logins, passwords and (on the most modern of Mac systems) fingerprint unlocking; I like knowing my files and documents are reasonably safe and secure.
Still, when you have a computer like an Apple iMac sitting in your kitchen or den and it’s just you and your cats, you and your spouse, or, heck, you and your houseplants, odds are very good that you don’t need to prove your identity every time you grab a cup of tea or go for a walk. The computer doesn’t know this, however, and – so far, at least – it doesn’t know whether you’re living solo or in a busy cubicle farm, so its default is to assume the worst and lock you out.
Both Mac and Windows computers make it easy to change this setting, but since you have an iMac, let’s focus on that. Instead of using the Apple > System Preferences… route, however, let’s do something different. Press Command + [space] on your keyboard (e.g., press and hold down the Command key, then also press the space bar) to launch Spotlight.
You’ll see a box in the middle of the screen like this:
Now since you want to change what happens when your computer goes to sleep, let’s just search for the word “sleep”. Do that by typing it in and then watch to see what happens; no Return or Enter key to press…
You don’t want the Energy Saver, but look two further down on the list. What you want instead is “Security & Privacy“, a logical place to find a password related security setting. Click on this option within the Spotlight window and it’ll open up System Preferences with the Security & Privacy window in the correct spot:
You have to admit, that’s a fast and easy way to find the correct setting on your iMac!
To change the setting – and notice mine is set to require a password after 5 minutes of inactivity – you’ll need to unlock the preferences window, which is done by clicking on the yellow padlock icon on the bottom left. A click and it prompts you for your account password (or an administrative account password if you don’t have an admin account):
Once you’ve unlocked it, you can look more closely at the setting options to see what you want to change to get that pesky iMac to work exactly how you’d like:
Notice also that if you click on the menu that shows your current password timeout (mine is “5 minutes”) there are a lot of different options from which to choose:
Given your setup, I recommend you consider something like 4 hours, so that you’ll need to log in every morning to access your files, email, photos, etc, but during the day you’ll just be able to wake up the computer and keep going, even after an extended lunch break or dinner out with friends.
Good luck and please don’t forget to check out the extensive Mac help here on the site!
Search: osx caffeinate
On Security and Privacy, General, click the lock to log in to make changes. Change to 4hours AND click on ‘Advanced’ at bottom right – this also needs to be changed, and type in ‘240’ (minutes). Click the lock again to confirm the changes.
Dear Dave,
You described the way MacOS used to work to shut off the Automatic Log Out, but not anymore––at least not on one of my MacBooks. With the advent of Mojave MacOS 14.5, the Energy Saver and Security & Privacy Preferences will not prevent the Auto Log Out from happening––that’s on my small MacBook (Retina, 12-inch, Early 2016). No matter how I make the Preferences settings, when I have music streaming from an internet source and I haven’t touched the Keyboard for between 10 and 15 minutes, the computer stops playing the Internet stream and displays a Login Window. This has happened dozens of times, Incidentally, the Mojave System Preferences panes look somewhat different from the earlier ones that you depict on your Answers page. To make things more mysterious, I don’t have this problem on another, bigger, MacBook running Mojave MacOS 14.5. The “good” Mac is a MacBook Pro (Retina, 15-inch, Early 2013). Nobody on the Internet seems to have a remedy for this problem. They all cite, as you do, the settings for MacOS’s previous to Mojave.
Can anybody out there solve this problem??? Same issue here for over a month since I erased the HD and reinstalled Mojave on a 2012 iMac, trying over and over again, researching over and over again for a solution. I inherited this iMac from my ex, erased the HD and then reinstalled Mojave (I am the administrator). It is hardwired for a logout at 5 minutes no matter any of the settings I can do in Security and Privacy or in Energy Saver. Nothing I’ve tried, searched for, or hoped for has solved the issue. It’s like “Ten-second-Tom” in “50 First Dates.” I have also erased the HD again and reinstalled Mojave with no change.
Hoping there is a solution somewhere out there.