Minimising App Windows Into their Respective Icons On The Dock To Create Less Clutter?

I think you are looking for this feature:

(System Preferences => Dock)

enter image description here

I just tried it on my own system and it when you minimize, it minimizes on the icon. You can click the icon to make the minimized window appear again.

You didn't mention what version of OS X you are on; I'm on Mountain Lion (OS X 10.8.4).


@sameetandpotatoes Has the answer for the question, but for additional info that you are confused about then to understand why the Dock behaves like this you need to understand the differences between Modal and non Modal windows.

Some applications, for example the Preferences app, only ever have 1 window, and therefore it makes sense for them to minimise into their doc icon rather than create a secondary icon. Often, for this type of app, closing the last window (i.e. the only window) also closes the app.

Others, like Pages, are not tied to a single window, but can have many document windows open, and therefore each get's it's own document icon in the dock (the simple way of thinking about the dock is that Apps go to the left of the divider, docs go to the right). Closing a Pages window won't kill the app, even closing the last one won't kill the app, because it knows that you may want more.

For convenience, as per @sameetandpotatoes answer you can choose to stack your document icons on top of the relevant App icons, and this will make the doc more clutter free, at the expense of potentially taking a little longer to navigate between windows.