[Tex/LaTex] No page numbering on ToC, LoT, LoF

page-numberingtable of contentstocloft

I'm trying to supress page numbering in the table of contents, list of figures and list of tables. If they have more than one page, subsequent pages should have no page numbering also, but they must still count as pages, for when page numbering actually starts.

I was hoping if you guys could help me out. Since I had no success until now, I don't even have an MWE, but here are some of the things I've already tried:

\let\oldtableofcontents\tableofcontents
\renewcommand{\tableofcontents}{\pagestyle{empty}\oldtableofcontents}

or, with the tocloft package:

\renewcommand{\cfttoctitlefont}{\pagestyle{empty}\clearpage}
\renewcommand{\cftloftitlefont}{\pagestyle{empty}\clearpage}
\renewcommand{\cftlottitlefont}{\pagestyle{empty}\clearpage}

Edit: I am trying to add this as part of my university's TeX class, which is hosted on CTAN and our GitHub page (I suggest you check the latter, I just fixed it). All the documentation is written in Portuguese, but you can see the cls and the manual, which was done using the class file. It is based on the report class.

I was able to fix some things by implementing Gonzalo's answer, i.e. by adding

\tocloftpagestyle{empty}

to the class and surrounding the calls for my lists with a call for \pagestyle{empty}. But the ToC still shows the page numbers after the first page (you can see it in our GitHub manual, page 15).

Best Answer

Using tocloft, add

\tocloftpagestyle{empty}

to have the first page of the ToC, LoF and LoT with empty style; use \pagestyle{empty} in a group containing the lists for successive pages:

\documentclass{report}
\usepackage{tocloft}

\tocloftpagestyle{empty}

\begin{document}

\clearpage    
{
\pagestyle{empty}
\tableofcontents
\clearpage
\listoffigures
\clearpage
\listoftables
\clearpage
}

\section{Test section}
\subsection{Test subsection}
\section{Test section}
\subsection{Test subsection}
\section{Test section}

\end{document}

Without packages, one can do something like

\documentclass{report}

\makeatletter
\let\ps@mystyle\ps@plain %HERE
\let\ps@plain\ps@empty
\makeatother

\begin{document}

\pagestyle{empty}
\tableofcontents
\clearpage
\listoffigures
\clearpage
\listoftables
\clearpage

\makeatletter
\let\ps@plain\ps@mystyle %HERE
\makeatother
\pagestyle{plain}

\section{Test section}
\subsection{Test subsection}
\section{Test section}
\subsection{Test subsection}
\section{Test section}

\end{document}

In the lines marked % HERE, change plain to the default page style for "regular" pages.

Related Question