I would like to set my chapter/section/subsection headings to use a sans-serif font, but keep the serif font for the body text. How can this be done?
10
votes
4 Answers
23
votes
You can use the sectsty
LaTeX package.
Put this in the preamble:
\usepackage{sectsty}
\allsectionsfont{\sffamily}
9
votes
2
votes
For the people who want to know why this has to be done differently from e.g. normal text. It is because of the distinction between robust commands and fragile commands. Headings do not allow fragile commands, so you have to specifically tell latex it is robust for example.
This link explains this further, and this link shows another alternative to do it.