natbib
Provides flexible citation and bibliography management with support for both author-year and numbered reference styles.
Overview
Enhances bibliographic capabilities by offering sophisticated citation formatting and reference management tools essential for academic writing and research publications.
- Supports multiple citation styles including author-year (e.g., 'Smith 2020') and numbered formats ([1]).
- Allows customizable citation commands for different contexts (e.g., parenthetical, textual citations).
- Includes compatible BibTeX styles (plainnat, unsrtnat, abbrnat) for consistent formatting.
- Particularly valuable for academic papers, theses, and research documents where precise citation formatting is crucial.
- Enables fine-grained control over citation appearance and bibliography formatting without changing the underlying database.
Getting Started
To use natbib
, include it in your document preamble:
\documentclass{article}
\usepackage{natbib}
\bibliographystyle{plainnat} % or unsrtnat, abbrnat
\begin{document}
Cite references using \cite{key} or \citep{key} for parenthetical citations,
and \citet{key} for textual citations.
\bibliography{mybibfile} % your .bib file (without extension)
\end{document}
Make sure to compile your document with: latex → bibtex → latex → latex
Examples
Using natbib for author-year citation style in a research paper.
\documentclass{article}
\usepackage{natbib}
\bibliographystyle{plainnat}
\begin{document}
According to \citet{Lamport1994}, \LaTeX\ is a document preparation system.
Other research \citep{Knuth1984} shows that \TeX\ is widely used in academia.
Multiple authors can be cited together \citep{Lamport1994,Knuth1984}.
You can also add text within the citation, such as \citep[see][p.~42]{Lamport1994}.
\bibliography{references}
\end{document}
Using natbib with numbered citation style for a scientific article.
\documentclass{article}
\usepackage[numbers]{natbib}
\bibliographystyle{unsrtnat}
\begin{document}
The typesetting system \TeX\ was developed by Knuth~\cite{Knuth1984}.
Later, Lamport created \LaTeX\ as a higher-level system~\cite{Lamport1994}.
Multiple references can be cited together~\cite{Knuth1984,Lamport1994}.
Specific pages can be referenced as well~\cite[p.~100]{Lamport1994}.
\bibliography{references}
\end{document}
Using natbib with custom citation commands and formatting options.
\documentclass{article}
\usepackage[round,authoryear]{natbib}
\setcitestyle{aysep={,}}
\bibliographystyle{plainnat}
\begin{document}
\section{Different Citation Commands}
\subsection{Basic Citations}
\citet{Lamport1994} developed \LaTeX.
\citep{Knuth1984} created the underlying \TeX\ system.
\subsection{Variations}
Text by \citeauthor{Lamport1994} from \citeyear{Lamport1994}.
See also \citealt{Knuth1984} for more information.
\subsection{Partial Citations}
\citeauthor{Lamport1994}'s work on \LaTeX\ in \citeyear{Lamport1994}.
\subsection{Multiple Citations}
Several researchers have contributed to typesetting \citep{Knuth1984,Lamport1994}.
\bibliography{references}
\end{document}