Good question! Even the native Chinese people, I think, could not give out a completely correct answer to it. Allow me take a try.
'窗' or ‘窗子' is a general designation of window, including all parts of window.
'窗口' is used to define the open space or room around in the range of window's frame.
'窗户' is similar to '窗' or ‘窗子', which is a more formal usage. Somtimes it is used specially to describe the big window which can be opened and closed.
In addition, ‘窗台' is the flat plat at the bottom of window.
Hope being helpful for you.^_^