Disclaimer: This answer is subjective. Good references to support claims are missing, even if the reason is based on my understanding of R. Bringhurst's Elements of Typographic Style.
Main text: Serif typefaces are known for being more readable (in terms of content understood per unit of time), as serifs guide the eye through the line. (Of course, this is true for well designed typefaces.)
This is why they are often chosen as font for the main text.
Headings: The purpose of headings is to highlight the structure of the reason in the text. Headings should thus contrast with the main text.
My claim is that because widespread typefaces are often constituted of a few fonts only (e.g., the Times New Roman typeface is available through its regular, italic, bold and bold-italic fonts only), and because the man in the street lack of knowledge in typography/aesthetic design (and that's normal), the common choice for headings' typeface is sans-serif.
On-screen reading: Note that this reasoning is verified in the reverse direction is some websites where the main text is typesetted in a sans-serif typeface (as sans-serif font are more readable on screen, as serif might appear blurred) and headings thus use a serif font.
Is this a good thing? I would prefer steering you towards renowned sources. It also depends on your objective: do you want your text to be a medium for conveying ideas, or do you want it to be admired?
My understanding is that one should balance the contrast between headings and the main text (i.e., increasing contrast) versus the global unity of the document (i.e., decreasing contrast).
My rule of thumb would thus be: change one setting at a time.
That is you between 'main heading' and 'sub heading', or between 'sub heading' and 'main text', you may change either the font size (10, 12, 16pt.), or the font weight (thin, regular, semi-bold, bold, ...), or the slope (regular, italic - slanted), or the caps (regular, small caps, full caps), or the serif, etc. But not all at the same time.
A good example of this is the book mentioned above, in which Bringhurst uses one (serif) type face only for the whole text. Only captions of full-page figures are typesetted in a sans-serif type face.
Beautiful (as synonym of 'noticeable') design does not mean good (as synonym of 'functional') design.