What happens when you close your MacBook Pro lid? Various questions

OK, it’s weird. I thought it had been going black when I close the lid, but it does not. The external display seems to get somewhat brighter/bluer in tone, and I can move the cursor around.

What’s weirder is as soon as I open the lid everything disappears from the external display and is moved to the main display! (I used Display Maid to restore the windows - very convenient app.)

So what does this mean?

Maybe TidBits needs a “Taking Control of Sleep” book. :)

1 Like

You mean, like in this article? :slight_smile:

2 Likes

Sounds like you are entering clamshell mode.

The color shift sounds like the color profile is changing. Try (re-)selecting your display’s profile from Settings → Display → Color, while your Mac is running in this mode.

I think what’s going on is that when you enter clamshell mode, you’re switching from a dual-display configuration (I assume you are not using display mirroring) to a single-display configuration. So everything is moved to your external display - because the content would otherwise be inaccessible.

And that external display becomes your primary display, because it’s the only one at the time.

When you open the lid, you’re going back to a dual-display scenario. Since the internal display is (I assume) becoming your primary display, all content is moved from the external (previously-primary) display to it. Which is what you are seeing.

If you make your external display the primary display, then this shouldn’t happen. When you open the lid, the primary display will remain the external display and all the windows will remain there. But windows that were on the internal display before you closed the lid won’t move back, because macOS doesn’t remember the previous positions when displays get reconfigured.

I think Display Maid (or any other similar utility) is probably the best solution for you.

2 Likes

According to your screenshot, you have this option checked:

  • Prevent your Mac from automatically sleeping when the display is off

That means when you shut your lid (and the display shuts off), your laptop does not go to sleep.

Most people do not have that checked, as the default behavior is sleep.

P.S. BTW, I used Monterey’s “image to text” feature to copy and paste that line exactly from your screenshot without having to type it! Love it! :grinning:

My (Mojave) system does restore windows. I have a 2017 MBP with an Apple Thunderbolt monitor. The external monitor is the primary. If I close the laptop, any windows there move to the external. When I open the laptop, the windows move back, and are restored just as I left them. I have no third party apps that affect this.

One setting which is probably relevant: System Preferences → Mission Control → check “Displays have separate Spaces”.

1 Like

I don’t think that’s correct. That setting is intended to prevent the Mac from going to sleep when the display sleeps, but that’s display sleep as defined by the user (Sys Prefs > Battery> Turn display off after) and independent from lid position. When you actually close the lid you are telling the Mac to go to sleep, not just the display (except of course for clamshell mode). That is then also turns off the internal display is a side effect of that.

So… what defines clamshell mode?

It’s just a colloquial term for a laptop running with the lid closed. There really isn’t a technical definition.

I guess I’m left with some confusion. It sounds like most people are saying that closing the lid should put it into sleep mode and that’s that. But if I close my lid things remain on the external monitor. One person wrote that since I was in clamshell mode (no idea how I got there) then everything moved to the external monitor and when I opened the lid everything moved to the internal display (thus I used Display Maid to restore). I guess that makes the most sense, though I’m not sure how I ended up using clamshell mode.

I guess one question I have is - if I’m not using an external keyboard is there any reason to not close the lid at night, or when I go out, and let the MBP go to sleep. Just to keep it from getting dusty? Are there any drawbacks from letting it go to sleep when not using it?

Thanks, Adam. That was helpful. :slight_smile:

If you close the lid when you have an external display, KB, and power connected, you are going into clamshell mode.

If you want to sleep your Mac without going into clamshell mode, don’t close the lid. Instead, select Apple Menu > Sleep. Once your Mac is asleep, you can close the lid if you like. If you then press a key, it will wake up in clamshell mode. If you want it to wake up without going into clamshell mode, open the lid instead.

1 Like

I don’t have an external monitor or any Bluetooth things connected to my MacBook, so it normally will go to sleep if I close the lid. To prevent this (when my MacBook needs to provide some network services, for instance) I activate a utility called NoSleep, which precisely does what it claims.

But it is easy to forget to deactivate this when not needed, so I sometimes end up with a hot but juiceless MacBook in my backpack…

I’m not the expert on clamshell mode, but based on what I’ve read about it, I think you’re going there simply because you have an external display and mouse connected.

I suspect (but don’t know) that it won’t happen if you disconnect the mouse. Give it a try. Does the external display remain on when you close the lid with no external input devices connected? Or does it go to sleep?

If you want to put it to sleep without closing the lid, you should be able to do one of:

  • Change the Energy Saver/Battery settings to let the Mac sleep when the display sleeps. Then let it wait until the time limit (which you set to an hour in your screen-shot)
  • Select Sleep from the Apple menu
  • Press the power button and then select sleep from the popup window. (At least I think this still works - it does on my 2011 MacBook Air).

Once it is asleep you should (I assume) be able to close the lid (if you still want to) without waking it up. The only advantage to doing so is dust (as you mentioned) and to prevent a spurious wake-up from something pressing a key (e.g. if you have children or cats).

No longer works that way. Hitting the TouchID button is equivalent to Lock Screen (ctrl-cmd-q).

These days if you want sleep you have to select it from the Apple menu.

When the monitor times out in an hour or whenever, will it then go to sleep if the lid is closed? Or will the mere presence of my bluetooth magic mouse keep it awake? Or does the mere fact the monitor is connected keep it awake?

I’m not an expert either, but I’ve experimented with closing the lid on my M1 Max MBP running Monterey and found that it enters clamshell mode [1] when I close the lid if my external display is connected via a USB-C to DisplayPort cable, even if no external (Bluetooth) mouse or keyboard are active. The MBP’s integrated keyboard and tracking pad are active, but when the lid is closed they are not accessible, so there’s no reason for them to inhibit clamshell mode.

I think that’s reasonable behavior because the Mac will be able to enter clamshell mode even when the Mac is only displaying information and doesn’t need input. (A display showing flights at an airport, for example.)

I’ve also confirmed that the Mac goes to sleep if I close the lid without an external display, even if an external (Bluetooth) mouse and keyboard are attached. It stays asleep (with the lid closed) even if keys on the keyboard are tapped or the mouse is clicked. (I have an app that incidentally logs when the computer sleeps or wakes; I suppose you could also find that info somewhere in a log in Console.app.)

[1] By “clamshell mode”, I mean a mode in which all of the items on the Desktop of the MBP’s built-in display are moved to the Desktop of the external display. They are moved back to the built-in display when the lid is opened and “clamshell mode” is exited.

I’ve also noticed that my external display (a Dell U2713HM) changes color slightly when in clamshell mode. This isn’t the same as the dimming when on battery – when this happens slightly creamy whites turn a bit “blue-ish” to my eye.

1 Like

Just out of curiosity (don’t want to digress) - how’s the light leakage from your new MBP? (See New MBP M1 Pro keyboard backlighting - uneven light leakage under keys?).

My guess about the turning a bit “blue-ish” might be because when the lid is closed, True Tone shades which are borrowed from the main display become inactive. It looks more “blue-ish” when you toggle off True Tone as well. I do that on my iPhone X because True Tone looks dull and faded to me there. But it seems easier on the eye on my MBP.

1 Like

The lights leakage under my keys is about the same as on my 2012 MacBook Pro. In fact, I posted a photo of that in discussion you linked to. It doesn’t bother me because I rarely view the keyboard from such a shallow angle.

Your guess is correct about the color change on my external screen when in clamshell mode: When I switch True Tone off in System Preferences >> Displays for the built-in display, the external display changes to what I referred to as “blue-ish”.

True Tone “automatically adapts display to make colors appear consistent in different ambient lighting conditions.” The MacBook’s ambient light sensor can’t detect what the conditions are when the MacBook is closed. When True Tone is working, it changes the colors on both the built-in and external displays to keep them consistent between displays.

2 Likes

Glad to hear we figured it out. You can probably run a display calibration with the lid closed to try and make it closer to your preference. If you find it adversely affects the appearance with the lid open, you can always switch it back to the default display profile.