Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

I need to make my (BibTeX) references section appear in the table of contents of my LaTeX document (documentclass: article), with section numbering too.

My approach until now has been making a new section and including the bibliography (references.bib) at that point:

\section{References}
\bibliography{references}

However, the final document shows both the section title that I have written and the section title that BibTeX writes, which is quite redundant and I definitely dislike.

How can I either remove BibTeX's section title, or make the BibTeX bibliography appear in the table of contents without making a new section?

If I were to make the BibTeX bibliography appear in the table of contents without making a new section, how could I assure that the section title that BibTeX writes looks exactly like sections typeset with \section?

share|improve this question
2  
which documentclass you are using? –  Herbert Jan 7 '11 at 15:34
3  
The information on this related question might be useful. –  Juan A. Navarro Jan 7 '11 at 15:46
    
@Juan: The related question was actually more tricky because it included "downgrading" the bibliography from a chapter to a section. –  lockstep Jan 7 '11 at 15:50
    
@Herbert: I am using the article documentclass. –  Genba Jan 7 '11 at 15:55

4 Answers 4

up vote 37 down vote accepted

As Herbert has hinted, your document class may include options to control the inclusion of the bibliography in the table of contents. For standard classes (article, book, report), adding \usepackage[nottoc,numbib]{tocbibind} to your document preamble should work. See the tocbibind documentation for more details.

EDIT: Herbert's suggestion (adding \addcontentsline{toc}{section}{References}) may result in an incorrect ToC entry unless the Reference section is forced on a separate page with \clearpage:

\documentclass[11pt]{article}

\usepackage{filecontents}

\begin{filecontents}{\jobname.bib}
@misc{A01,
  author = {Author, A.},
  year = {2001},
  title = {Alpha},
}
\end{filecontents}

\usepackage{blindtext}

\begin{document}

\nocite{*}

\tableofcontents

\section{foo}

\blindtext[3]

% \clearpage

\addcontentsline{toc}{section}{References}
\bibliographystyle{plain}
\bibliography{\jobname}

\end{document}
share|improve this answer
    
If I want that Bibliography not appears in TOC? –  hsigrist Nov 2 '11 at 22:53
    
@hsigrist: This is the default behaviour in many classes. –  lockstep Nov 2 '11 at 22:55
1  
The first suggestion is nice (tocbibind), but it changes the name of the section from "References" to "Bibliography". The former is more accurate in my case. Is there a simple way to change it back? –  naught101 Apr 26 '12 at 6:40
1  
this: \settocbibname{References} –  naught101 Apr 26 '12 at 6:46
    
This doesn't work for me. I use report. Check out the complete source and the result document. –  Emanuel Berg Feb 27 '13 at 2:06

The following should help, I think:

\documentclass[bibtotocnumbered]{scrartcl}
share|improve this answer
3  
This works indeed, but forces you to use the KOMA classes. –  Henri Menke Aug 6 '13 at 19:24

Using hyperref, one should say:

\cleardoublepage

\phantomsection

\addcontentsline{toc}{chapter}{Bibliography}

\bibliography{your_bib_archive}
share|improve this answer
\documentclass{article}
\begin{document}

\tableofcontents

\section{foo}
\nocite{*}% only for demo to get the entries from komoedie

\let\Section\section 
\def\section*#1{\Section{#1}} 
\bibliographystyle{plain}
\bibliography{komoedie}

\end{document}
share|improve this answer
    
@Herbert: This will always place the Reference section on a separate page, which may not be appropriate for the article class. –  lockstep Jan 7 '11 at 16:17
    
@lockstep: sure, this is what I prefer. If one want it not start at an own page then deleting of clearpage maybe a good idea ... :-) –  Herbert Jan 7 '11 at 16:19
1  
@Herbert: Assuming one deletes clearpage, could it happen that \addcontentsline will point to the wrong page if the Reference section by chance starts a new page? (I dimly remember that I stumbled upon such behaviour once, but I'm not sure about it.) –  lockstep Jan 7 '11 at 16:25
    
@Herbert: I reproduced the problematic behaviour - see my edited answer. –  lockstep Jan 7 '11 at 20:23
2  
@lockstep: ah, a competition, I like it :-) No extra answer by me, because it didn't help the one who ask a question ... However: \let\Section\section \def\section*#1{\Section*{#1} \addcontentsline{toc}{section}{References}} \bibliography{\jobname} –  Herbert Jan 7 '11 at 20:50

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.