After upgrading to macOS Sonoma or Sequoia, some users have noticed a frustrating bug: certain application windows remain stuck in focus, making it impossible to click on or interact with windows behind them.
Weird random glitch in Sonoma for me. I can only open one window on my Mac desktop. I tried Command + Tab, but nothing worked. Anyone else seeing this? -forums.macrumors.com
This issue disrupts productivity and creates a poor user experience. Fortunately, there are several reliable fixes you can try to regain control over your desktop. This guide from iBoysoft will walk you through step-by-step solutions to resolve the macOS Sonoma stays in focus problem.
# 1 Switch Focus manually
If a window won't release focus, try shifting it with Mission Control or App Switcher:
- Use Mission Control: Swipe up with three or four fingers on the trackpad or press "Control + ↑". Then click on the desired window to bring it to the front.
- Use App Switcher: Press "Command + Tab" to cycle through open applications. Hold Command and tap Tab until you reach the app you want to switch to, then release.
# 2 Force quit and relaunch the affected app
If a single app is misbehaving:
- Press "Command + Option + Esc" to open the Force Quit window.
(Or you can click the Apple menu > Force Quit.) - Select the problematic app and click "Force Quit".
- Reopen the app normally to see if the issue is fixed.
# 3 Restart WindowServer
WindowServer Mac manages all graphical elements in macOS. Restarting it can often reset weird window behaviors:
- Finder > Applications > Utilities > Activity Monitor.
- Search for WindowServer.
- Select it and click the X button to quit.
This will momentarily log you out, so save your work first.
# 4 Reset Dock & Mission Control
Corrupted Dock or Mission Control settings might cause a focus issue, like Sonoma Window stays in focus.
- Finder > Applications > Utilities > Terminal.
- Type the commands one by one and press the Enter key.
defaults delete com.apple.dock
defaults delete com.apple.spaces
killall Dock
# 5 Disable app-specific focus features
Some apps may have their own focus or "always-on-top" settings. For example:
- Check Apple menu > Settings > Accessibility > Display in the app (if applicable).
- Look for any "stay on top" or "focus lock" options within the app's preferences and disable them.
# 6 Delete app preferences
Corrupted preference files can also cause focus glitches. To remove them:
- Finder > Go > Go to Folder > Type ~/Library/Preferences/ and press the Enter key.
- Locate the file that starts with "com.[appname].plist".
- Move it to Trash.
- Restart the app.
This resets the app's settings, potentially resolving the issue.
# 7 Reset NVRAM and SMC
If none of the above works, resetting your Mac's system management controllers may help:
Reset NVRAM:
- Shut down your Mac.
- Turn it on and immediately press and hold Option + Command + P + R for about 20 seconds.
Reset SMC (for Intel Macs):
- Shut down your Mac.
- On laptops: Hold Shift + Control + Option + Power for 10 seconds, then release and turn it on.
For M1/M2 Macs, just shut down and wait 30 seconds before restarting.
The "macOS Sonoma stays in focus" bug can be annoying, but it's usually not a permanent problem. Have you fixed it with the fixes above? Share our post.