Introduction

Page numbering is an important aspect of a document's formatting and organization. It helps readers easily navigate the document and provides a reference for citation. LaTeX provides several methods for adding page numbers to a document. Whether you want to add page numbers in the header or footer, set a specific starting number, or change the numbering style, LaTeX has the tools to get the job done. With the ability to control the placement and appearance of page numbers, you can ensure that your document looks professional and meets your specific needs.

Page numbering in LaTeX

In LaTeX, page numbers can be added using the \pagenumbering{style} command, where style can be one of the following:

  1. arabic for standard numbers (1, 2, 3, ...)
  2. roman for lowercase Roman numerals (i, ii, iii, ...)
  3. Roman for uppercase Roman numerals (I, II, III, ...)
  4. alph for lowercase letters (a, b, c, ...)
  5. Alph for uppercase letters (A, B, C, ...)

The page numbering can be started from any number by using the \setcounter{page}{number} command, where number is the desired starting page number.

Here is an example of how to use the \pagenumbering{style} command in LaTeX:

\documentclass{article}
\usepackage{blindtext}
\begin{document}

\pagenumbering{arabic} % Sets page numbering to arabic (1, 2, 3, ...)
\setcounter{page}{1} % Specifies the starting page number

\section{Introduction}
\blindtext[5]

\section{Methods}
\blindtext[5]

\section{Results}
\blindtext[5]

\end{document}

This example generates the following output:

page numbering example

Tips:

  • In this example, the \pagenumbering{arabic} command changes the page numbering style to arabic, which means that the page numbers will be displayed as 1, 2, 3, ...
  • The \setcounter{page}{1} command specifies the starting page number as 1.
  • You can change the style argument to roman for lower-case Roman numerals (i, ii, iii, ...) or alph for lower-case alphabets (a, b, c, ...) depending on your requirement.

By default, page numbering starts from the first page of the document. However, it is possible to restart the page numbering in different parts of the document. This can be achieved using the following command:

\setcounter{page}{1}