I need to restart the WindowServer (OS X's GUI); I know this can be achieved using the command sudo killall -HUP WindowServer but this closes all your open applications. Is there a way to restart the WindowsServer without it quitting all your open applications?


5 Answers 5


You can also try:

killall -KILL Dock
  • 1
    Does killing the Dock restart the WindowServer?
    – nohillside
    Sep 30, 2015 at 8:35
  • @patrix It restarts some parts of the UI interface (not sure which). In my case, the top bar was not displaying (time, clock, sound and wifi were invisible...). Restarting the dock fixed the problem. Sep 30, 2015 at 8:37
  • Fair point, but how does this relate to the problem described in the question?
    – nohillside
    Sep 30, 2015 at 8:38
  • @patrix It's a way to restart parts of the UI without quitting all your open applications. That might help the OP. Sep 30, 2015 at 8:39
  • This works quite well when needing to restart the crashed Video portion of the Mac OS X GUI, which was preventing a login via VNC / Mac Remote Desktop. I could still login via SSH, issue the killall -KILL Dock command and have the majority of the apps remain functional and the user still logged in. At the same time, VNC remote access was restored. Thank you sir!
    – Darkstar
    Jul 1, 2017 at 4:08

There is no way to restart window server without closing all apps; logging out & then back in is the best option


The WindowServer is responsible for drawing all Windows and Windows Content for all Programs (incl. Finder), so it would not be possible to kill the Process without killing all Applications.

You can read about the Window Server in the Apple Technical Note TN2083 for OSX 10.5.

Even though it is announced in that Document that Apple plans to change the Behaviour in future Systemversions, it's in your list of required OS's.

  • 1
    I think the note about removing it is referring to the fact that the window server is available from the global bootstrap namespace, not removing the entire window server.
    – ughoavgfhw
    Sep 12, 2011 at 22:34
  • "not possible" is stretching it, as Linux X window managers can restart fine without closing applications. Apple's architecture does not seem to allow restarting windowing without closing all applications. Sep 11, 2020 at 5:18
killall Finder         # what should work
killall SystemUIServer # what to run in addition if it does not

If any of the two do not restart (finder sometimes does not automatically reboot in my experience), then run these commands after the initial set:

open -a Finder
open -a SystemUIServer

This set of commands (specifically killall Finder) is almost exactly like taskkill /IM explorer.exe within the MS-DOS command line.


If this is to restart the GUI without quitting all applications (to solve UI jitter, a duplicate mouse cursor, etc...) I found turning off the display works as well.

This earlier question has some information on how to do this.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .