I am new to latex, During writing my thesis, I have come to a stage where I have to add a lot of \subsections,\subsubsections,\subsubsubsections. What I would like to show numbering scheme in the chapters. but I do not like to show the numbering of subsubsubsections in the Table of contents. I just would like to show main heading in table of contents. But my table of contents showing each subsections and \paragraph in the table of content.

Response will be highly appreciated.

Thanks.

• \setcounter{tocdepth}{2}in the preamble makes the table of contents display up to the \subsection level. Chapters have level 0, sections have level 1, &c. – Bernard Dec 24 '16 at 13:21
• Which document class do you use? – Mico Dec 24 '16 at 19:10

The table of contents (TOC) as a default show only up to level 3. unless you are using a custom class. Nonetheless, if you want to modify the appearance of the TOC, follow the below script

\setcounter{tocdepth}{2}

• The tocdepth option >> refers to the Table of Contents (TOC) and the option of modifying the appearance of how many levels to be shown.

• {2} >> refers to how many levels you want to be included.

If you want to increase the number of your headers (sections and subsections), follow the below script

  \setcounter{secnumdepth}{3}

• Likewise, the secnumdepth option >> refers to the sectioning number (sec) and the option of modifying the appearance of how many levels to be numbered.

• {3} >> refers to the numerical level of the deepest sectioning units showing up in the TOC.

Now, to know where you should include these scripts into your code.

\documentclass[11pt,a4paper]{report}

\setcounter{secnumdepth}{3}
\setcounter{tocdepth}{2}

\begin{document}
\tableofcontents

\chapter{Some chapter}
\section{Some section}
\subsection{Some subsection}
\subsubsection{Some subsubsection}
Text ...

\end{document}

• the description of "referring to how many levels" included in TOC is a bit wrong: in article class, \setcounter{tocdepth}{1} allows 2 levels: parts, and sections. But in report class it allows 3 levels because there is also chapters. It is more accurate to say simply that the tocdepth setting is the numerical level of the deepest sectioning units showing up in the TOC. – user4686 Sep 17 '17 at 13:02
• yes, thank you for your modification. I will update the answer – Ahmed Sayed Sep 17 '17 at 14:01