# Gobble page numbers

In my document I have 5 pages that consist of the chapter name. I want these pages not to have page numbers displayed and not to contribute to the page numbering.

This is what I am trying to achieve:

..., p5, p6, blank page, p7, p8, ...

By using \thispagestyle{empty} on the blank page and I get:

..., p5, p6, blank page, p8, p9, ...

where the blank page has been included in the numbering.

I then tried to use \pagenumbering{gobble} on the blank page and then \pagenumbering{arabic}

on the next consecutive page but the numbering was reset to give:

..., p5, p6, blank page, p1, p2, ...

How can I prevent the gobble input from resetting the page numbering?

• If you don't need to do this many times you can use the empty and set up the page counter by means of \setcounter{page}{7} or something else. – Sigur May 6 '13 at 13:31

Here's a little example of what you want. Note

• \thispagestyle{empty} suppresses the page number on the current page.

• You can fiddle with the page numbering using commands like \addtocounter{page}{-1}. (You could instead use \setcounter{page}{\thepage-1}, but that requires loading the calc package, which lets you evaluate numerical expressions like \thepage-1.)

Code:

\documentclass{article}
\begin{document}

First page
\clearpage
Second page
\thispagestyle{empty}
\clearpage
Third page

\end{document}

• @JohnWickerson -- i didn't actually mean to remove the other suggestions. they're valid, and under some circumstances might be preferable, so keeping them in the list could be useful. – barbara beeton May 6 '13 at 18:17
• What is the difference between using \setcounter{page}{\thepage-1} and \addtocounter{page}{-1} after the clearpage input? Both seem to give the desired effect, I'm just curious as the which would be best to use if I'm repeating it throughout the document. I expect there is not real advantage one has over the other...? – Alastair May 6 '13 at 18:36
• They have exactly the same effect, but \addtocounter{page}{-1} is a little bit shorter, and as @barbarabeeton says, doesn't require any extra packages to be loaded. – John Wickerson May 7 '13 at 4:34
• @Alastair: Please consider clicking on the tick mark next to an answer to 'accept' it, so that this question can be marked as resolved. :) – John Wickerson May 7 '13 at 18:02

If you want to keep hyperref happy, in case you use it, change the page number representation:

\documentclass{report}
\usepackage{hyperref}

\newcounter{nopage}
\newenvironment{nopage}
{\clearpage\stepcounter{nopage}%
\renewcommand{\thepage}{NP\arabic{nopage}}%
\thispagestyle{empty}}

\begin{document}

First page

\begin{nopage}
\chapter{A chapter}
\end{nopage}

Second page

\begin{nopage}
\chapter{Another chapter}
\end{nopage}

\end{document}

• When I implement your solution in an environment that spans more than one page, my typesetting for \thepage actually includes the NP at the bottom of the page. I thought the \thispagestyle{empty} would have been applied repeatedly for every instance of the renewed \thepage. Why does this show up? Thanks! Oh, the counter part keeping track of elapsed pages works fine though - which is why \thispagestyle{empty} not being repeated surprised me. – EngBIRD Apr 3 '16 at 4:42
• @EngBIRD You've chosen the wrong road, probably, but without an example it's difficult to say more – egreg Apr 3 '16 at 9:07
• Great thanks! Time permitting I will ask this in a new question then. – EngBIRD Apr 3 '16 at 16:51