Most Word users stop at page numbers and dates in their headers and footers, but Microsoft Word can do much more. From inserting document titles, authors, and file paths to using advanced field codes like StyleRef or NumPages, you can make your headers dynamic, informative, and even interactive. Discover the powerful, lesser-known elements you can add to give your documents a truly professional edge.
Some are listed in the Header & Footer | Insert ribbon like Date & Time or from the document properties (see File | Info):
- Author
- Document Title
- File Name
- File Path
All those choices are really Word field codes.
Word field codes, changing the color or format based on the number
All the \* named format switches for Word field codes
Really useful but not listed
The Header & Footer ribbon doesn’t offer some of the more useful things to put there. For those we have to dig into more field codes at Header & Footer | Document Info | Fields.
NumPages – add this to Page Number to make “Page 2 of 25”.
StyleRef
The most useful field code for a Header or Footer doesn’t get a mention in the ribbon.
StyleRef – inserts the name of the current Heading text
For example, two StyleRef codes like this
{STYLEREF "Heading 1" \* MERGEFORMAT} - { STYLEREF "Heading 2" \* MERGEFORMAT}
Can make a heading showing the first and second heading names for the current page, like a title and chapter name e.g.:
- A Study in Scarlet – The Science of Deduction
- Moby Dick – The Carpet-Bag
- Oliver Twist – Treats Of Oliver Twist’s Growth, Education, And Board
- My Brilliant Career – An Introduction To Possum Gully
More Document details
Some field codes are useful while the document is being drafted and can be deleted before publication.
NumWords – handy when there’s a word count involved.
SaveDate – the last time the document was saved.
CreateDate – when the document was created.
Add Document Navigation
For online documents or PDFs, the header or footer can have clickable links to other parts of the document like the Table of Contents.
Go to Insert | Cross-reference then choose Heading (or any other Reference type). Make sure the “Insert as Hyperlink” is selected before clicking Insert.
That inserts a link (as a REF field code) plus the text of the selected heading. That text can be changed simply by typing over the visible text. I sometimes change “Table of Contents” to “Click for ToC” or “Click for Contents” so readers know what to do.
Mastering Headers and Footers in Microsoft Word: Simple Steps for a Professional Look
Word field codes, changing the color or format based on the number