I'm trying to use fancyhdr to make a multiple line header with the following format:

Left Header     Center Header
                                 Right Header

Where the --- represent a horizontal line.

Basically I would like the left header to be a line under the other two, plus a separating line between both headers.

Is there a way to do so using redefining the headrule command?

  • Welcome! Please post a small, complete document illustrating the problem you are having implementing this. At the same time, please clarify your question. Do you really want the left header to be repeated below right?
    – cfr
    Commented Nov 24, 2015 at 3:33
  • What content should be placed in the Left Header, Center Header and Right Header, respectively?
    – Werner
    Commented Nov 24, 2015 at 3:39
  • @Werner There should be an Image on Left Header, some text on Center Header and section name on Right Header, still my problem is with the middle horizontal line and the right justified horizontal end line
    – PeCosta
    Commented Nov 24, 2015 at 3:43
  • @cfr No, it was a mistake, I meant Right Header
    – PeCosta
    Commented Nov 24, 2015 at 3:45
  • Please provide some code. Not only does it make it easier to answer, it also makes it much less likely that the answer won't actually work for you.
    – cfr
    Commented Nov 24, 2015 at 3:49

1 Answer 1


There's a lot you can do in the headers. I've set the Left Header as-is, while the Center Header and Right Header is set using a tabular of fixed width. The advantage of using a tabular is that you can use its \hlines for rules:

enter image description here



\fancyhf{}% Clear header/footer
\fancyhead[L]{Left Header}
  \hfill Center Header \hfill \strut \\
  \strut \\
  \strut \hfill \leftmark \\


\section{First section}


Horizontal alignment is achieved using appropriately-placed\hfills, while vertical alignment is achived by the insertion of \struts.

The \headheight adjustment depends on the contents. In my case fancyhdr suggested to it to be at least 24.4pt, so I set it to 25pt.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .