# Show page number on chapter start pages too

Currently the page numbers are missing on pages where a chapter starts. I assume this is a setting inherited by \pagestyle{scrheadings}. But how can I add page numbers to chapter start pages too?

\documentclass[chapterprefix=true, 12pt, a4paper, oneside, parskip=half, listof=totoc, bibliography=totoc, numbers=noendperiod]{scrbook}
\usepackage{blindtext}

\automark{chapter}
\ifoot*{}
\cfoot[\thepage]{}
\cfoot*{}
\ofoot*{}

\begin{document}
\pagenumbering{arabic}
\chapter{One}
\Blindtext
\end{document}


• Hi, can you modify your MWE to be compilable? – Sango Oct 10 '19 at 10:45
• OK, demo code is now working as is. – Michael Oct 10 '19 at 10:58

By default chapter pages use page style plain. \ihead, \ohead etc. have a optional argument for the content on plain pages. If the content is the same on both plain and scrheadings pages, you can use the starred version, eg \ohead*{\pagemark} is a short version of \ohead[\pagemark]{\pagemark}.

I would suggest to use \pagemark for the page number in header and footer. Then the font element pagenumber (default is \normalfont\normalcolor) is taken into account.

Using \clearpairofpagestyles the predefined content of header and footer for page styles plain and scrheadings can be removed.

Note that package scrlayer-scrpage sets page style scrheadings automatically.

For onesided documents option automark does the same as \automark{chapter}.

Example:

\documentclass[chapterprefix=true,12pt, a4paper, oneside, parskip=half, listof=totoc, bibliography=totoc, numbers=noendperiod]{scrbook}
\usepackage{blindtext}

\clearpairofpagestyles
\setkomafont{pagenumber}{}% default is \normalfont\normalcolor

\begin{document}
\Blinddocument
\end{document}


Result:

If there should be a headsepline on plain pages too, add option plainheadsepline.

If you would use headsepline as class option, option headinclude would be set too (automatically).

After loading scrlayer-scrpage page style plain is an alias page style of plain.scrheadings.

• Well explained, thanks. It's working. I'll do it like this. – Michael Oct 10 '19 at 12:20

OK, I found the solution. \ohead command has {} for default pages and [] for the chapter start pages. According to the manual it has another meaning but it does what I want:

\documentclass[chapterprefix=true, 12pt, a4paper, oneside, parskip=half, listof=totoc, bibliography=totoc, numbers=noendperiod]{scrbook}
\usepackage{blindtext}

\automark{chapter}
\ohead[\thepage]{\thepage} % <- HERE: page number on chapter page and default pages
\ifoot*{}
\cfoot*{}
\ofoot*{}

\begin{document}
\pagenumbering{arabic}
\chapter{One}
\Blindtext
\end{document}


Another solution is from the documentation. http://www.pirbot.com/mirrors/ctan/macros/latex/contrib/koma-script/doc/scrguide.pdf and this link: https://golatex.de/renewcommandchapterpagestyle-t3048.html

\documentclass[chapterprefix=true, 12pt, a4paper, oneside, parskip=half, listof=totoc, bibliography=totoc, numbers=noendperiod]{scrbook}
\usepackage{blindtext}

\automark{chapter}
\ifoot*{}
\cfoot[\thepage]{}
\cfoot*{}
\ofoot*{}

• The \cfoot is in the group too, so in the resulting pdf there is no page number in footer. Additionally the OP does not want a page number in footer. Therefore remove {\cfoot{-{ }\pagemark{ }-}} too. – esdd Oct 10 '19 at 12:36