# How to get a big table on a page with pagestyle empty?

In my document I have a table that is quite big. I would like to have this table on a page with no header and no page number. How can I get this table on a \thispagestyle{empty}? Using it withing the table or tabular environment makes the page were the float is defined go empty and leaves the headers on the table.

For if it matters, I am using fancyhdr.

-
– barbara beeton May 18 '13 at 12:45

fancyhdr provides the \iffloatpage macro that can be used to customize header and footer for pages which contain only floats.

\documentclass{book}

\usepackage{fancyhdr}
\fancyfoot{}
\fancyfoot[C]{\iffloatpage{}{\thepage}}
\pagestyle{fancy}

\usepackage[english]{babel}
\usepackage{blindtext}

\begin{document}

\blinddocument

\begin{table}[p]
\centering
(Table contents)
\caption{A table on a separate page}
\end{table}

\end{document}

EDIT: For those that want to use the \iffloatpage macro with KOMA-script's scrpage2 package instead of with fancyhdr, add the following to your preamble (thanks to Stefan Kottwitz for the tip):

\makeatletter
\makeatother

(The blindtext package is only used to add some dummy text to the example.)

-
Thanks, that works great! – Peter Smit May 30 '11 at 20:24
@Peter: By default, the table should be vertically centered. Tweaking the positioning paramaters still won't "reclaim" the header space, unless the table is too large for a normal page to begin with. There may be hacks to achieve what you want, but that's over my head. – lockstep May 30 '11 at 20:27
Thanks for that. I realized this immediately after I posted my comment, so therefore I removed it :) – Peter Smit May 31 '11 at 4:14

You can simply put the table on a page of its own without putting it inside a table environment. Then you can make use \thispagestyle{empty} before the table. To add the caption properly, use the \captionof command from the caption package.

-

When using the memoir document class the command mergepagefloatstyle can be used to separate pagestyles for regular pages and pages with only floats, similar to @lockstep's soltuion. For example

\mergepagefloatstyle{floatcomp}{ruled}{empty}

defines a new style floatcomp that will use the pagestyle ruled for regular pages and empty for float-only pages.

A MWE:

\documentclass{memoir}
\usepackage{kantlipsum}

% Define new style floatcomp that usees 'ruled' style for regular
% pages, and 'empty' for float-only pages.
\mergepagefloatstyle{floatcomp}{ruled}{empty}
% Use previously defined floatcomp style
\pagestyle{floatcomp}

\begin{document}

\kant[1-5]

\begin{table}[p]
\centering
(Table contents)
\caption{A table on a separate page}
\end{table}
\clearpage

\kant[10-13]

\end{document}
-

Because there is no really satisfying answer to the question yet, I want to add an alternative to Alan's approach.

\clearpage
\thispagestyle{empty}
\begin{figure}
...
\end{figure}
\clearpage

This lets you keep the "float" as such, it just doesn't float anymore. That kinda sucks but this at least gives you another poison to choose from.

-