Document Formatting
How to Customize Section Numbering in LaTeX
LaTeX automatically numbers sections. Here's how to customize the numbering to match your needs.
Control Numbering Depth
Set how deep numbering goes:
% secnumdepth levels:
% -1 = no numbering
% 0 = only chapters
% 1 = chapters and sections
% 2 = ... and subsections
% 3 = ... and subsubsections
\setcounter{secnumdepth}{2} % Number up to subsectionsRemove Numbers from Specific Sections
Use starred versions:
\section{Numbered Section} % 1. Numbered Section
\section*{Unnumbered Section} % No number
% To add unnumbered to TOC:
\section*{Acknowledgements}
\addcontentsline{toc}{section}{Acknowledgements}Custom Number Format
Change how numbers appear:
% Roman numerals for sections:
\renewcommand{\thesection}{\Roman{section}}
% Produces: I, II, III...
% Alphabetic subsections:
\renewcommand{\thesubsection}{\thesection.\Alph{subsection}}
% Produces: 1.A, 1.B, 1.C...
% Start counting from different number:
\setcounter{section}{4} % Next section is 5💡 Tips
- •Journal templates usually handle numbering automatically
- •\arabic, \roman, \Roman, \alph, \Alph for different styles
- •tocdepth controls what appears in table of contents
Try This in Bibby AI
Write LaTeX faster with AI auto-complete and instant compilation.
Start Writing Free