let me preface this with saying I don't fully understand fancyhdr. I am trying to achieve getting the same header on every page: the left top showing the chapter number, section number and section title -- and the right top the page number. I.e.

  • 1.1 section title
  • 1.3 next section
  • 2.1 new chapter
  • bibliography (can manually switch styles for this)
  • A.1 appendix section
  • A.2 another appendix section

I can get this to work just fine in the normal chapters, but the approach fails when I use the 'appendix' package (which I use to achieve getting the 'appendix' entry in the TOC). A minimal example:


% Include appendix

% Fancyhdr
% Custom style:
\fancyhead[L]{\thesection. \rightmark}



\chapter{The Ghost Problem}
\section{Bill murray}

% ============================================================================
% = APPENDICES ===============================================================
% ============================================================================

\chapter{Other disasters}
    \section{Darth vader}


If you compile this file, you'll find that the last page will show 1.3 rather than A.3 in the header, basically falling back to the last know \leftmark information or so..?

If I use \appendix instead, this issue is not present. Any hints?

  • A warm welcome to TeX.SE! Excellent first question with a good, compilable, MWE.
    – A Feldman
    Jun 24, 2016 at 14:39

1 Answer 1


Just comment the renewcommand line and change \fancyhead[L] to something simpler.

% \renewcommand{\sectionmark}[1]{\markright{#1}}
  • 1
    Good, that fixes the numbering issue! I wrapped it in \nouppercase{\rightmark} to remove the smallcaps. Seems to work, thanks a lot! :-)
    – Erik
    Jun 24, 2016 at 14:49

You must log in to answer this question.

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