How to find out process owner of unidentified windows?

I have an odd error that I have not been able to associate with an application or PID properly.

In Windows, there is Process Explorer with the very handy target function that allows you to click it and then select a window to find the owner process:

target selector

Is there a way to do something similar in OS X that will allow me to find a seemingly orphaned window's owner such as this:

orphaned window

I have terminated every single process that can be terminated with the window manager running in OS X and yet I can still not isolate the owner.


Solution 1:

  • Download and install Xcode.
  • When installed open Xcode.
  • In the menubar go to Xcode > open Developer tool > Accessibility inspector
  • In the Access..Inspector menu go to Inspection > Enable point to inspect
  • Click on anything to see the result

It does not give you the process name, but it does give you the parent's application name

Solution 2:

I was also trying to figure this out and ended up using the solution described here. It's a Python script which lists all the processes with all the windows that belong to them and their coordinates on the screen. So it is not as easy to use as the Process Explorer on Windows, but it can get you the answer your are looking for. It helps if you can move the window to a place on your desktop with easily recognizable coordinates.