Quick start: BibTeX automates bibliography formatting in LaTeX. Create a
.bib file with your references, cite them with \cite{key}, and LaTeX handles the formatting based on your chosen style.Prerequisites: Basic LaTeX knowledge. For citations basics, see Bibliography & Citations.What You’ll Learn
- ✅ How BibTeX works with LaTeX
- ✅ Creating and managing .bib files
- ✅ Citation commands and variations
- ✅ Bibliography styles (plain, alpha, abbrv, etc.)
- ✅ Advanced customization techniques
- ✅ Best practices for reference management
- ✅ Troubleshooting common issues
How BibTeX Works
BibTeX is a bibliography management tool that works alongside LaTeX to handle citations and references automatically. Here’s the workflow:BibTeX Workflow
The BibTeX workflow follows four steps: (1) Create a .bib file to store your references in a structured format, (2) Cite references in your .tex document using \cite commands, (3) Compile using LaTeX followed by BibTeX and then LaTeX again, (4) Output shows your formatted bibliography with properly numbered or author-year citations matching your chosen style.
Basic Setup
Step 1: Create Your Main Document
Step 2: Create Your Bibliography File
Step 3: Compile Your Document
1
First LaTeX pass
pdflatex main.tex - Creates auxiliary files with citation information2
Process bibliography
bibtex main - Reads .aux file, processes .bib file, creates .bbl file3
Second LaTeX pass
pdflatex main.tex - Incorporates bibliography entries4
Final LaTeX pass
pdflatex main.tex - Resolves all cross-referencesRendered Output
The compiled document displays “Sample Article with Bibliography” as the centered title, followed by the author name and date. The Introduction section shows in-text citations as bracketed numbers [1] and [2]. The References section at the bottom lists the formatted bibliography entries: [1] shows Einstein’s article with author, title in sentence case, journal name in italics, volume, pages, and year; [2] shows Hawking’s book with author, title in italics, publisher, city, and year.
BibTeX Entry Types
Common Entry Types
@article
Journal articles, magazine articles
@book
Books with publisher
@inproceedings
Conference papers
@phdthesis
PhD dissertations
Complete Entry Types Reference
All BibTeX entry types with required and optional fields
All BibTeX entry types with required and optional fields
@article
Required: author, title, journal, yearOptional: volume, number, pages, month, doi, note
@book
Required: author/editor, title, publisher, yearOptional: volume/number, series, address, edition, month, isbn, note
@booklet
Required: titleOptional: author, howpublished, address, month, year, note
@inbook
Required: author/editor, title, chapter/pages, publisher, yearOptional: volume/number, series, type, address, edition, month, note
@incollection
Required: author, title, booktitle, publisher, yearOptional: editor, volume/number, series, type, chapter, pages, address, edition, month, note
@inproceedings / @conference
Required: author, title, booktitle, yearOptional: editor, volume/number, series, pages, address, month, organization, publisher, note
@manual
Required: titleOptional: author, organization, address, edition, month, year, note
@mastersthesis
Required: author, title, school, yearOptional: type, address, month, note
@misc
Required: noneOptional: author, title, howpublished, month, year, note, url
@phdthesis
Required: author, title, school, yearOptional: type, address, month, note
@proceedings
Required: title, yearOptional: editor, volume/number, series, address, month, publisher, organization, note
@techreport
Required: author, title, institution, yearOptional: type, number, address, month, note
@unpublished
Required: author, title, noteOptional: month, year
Citation Commands
Basic Citation Commands
Rendered Output
Citation commands produce different outputs depending on the bibliography style. With the plain style: \cite produces [1], multiple citations produce [1, 2], and page references produce [2, p. 42]. With author-year styles (natbib): \cite produces (Einstein, 1905), multiple citations produce (Einstein, 1905; Hawking, 1988), \citet produces Einstein (1905) for textual citations, and \citep produces (Einstein, 1905) for parenthetical citations.
Bibliography Styles
Standard BibTeX Styles
plain
\bibliographystyle{plain}Entries sorted alphabetically by author, numbered [1], [2], [3]…Example:- [1] A. Einstein. On the electrodynamics…
- [2] S. Hawking. A Brief History of Time…
alpha
\bibliographystyle{alpha}Labels like [Ein05], [Haw88] based on author and yearExample:- [Ein05] A. Einstein. On the electrodynamics…
- [Haw88] S. Hawking. A Brief History of Time…
abbrv
\bibliographystyle{abbrv}Like plain but with abbreviated first names, journal namesExample:- [1] A. Einstein. On the electrodynamics… Ann. Phys.
- [2] S. Hawking. A Brief History of Time…
unsrt
\bibliographystyle{unsrt}Entries in order of citation, not alphabeticallyExample:- [1] S. Hawking. A Brief History of Time…
- [2] A. Einstein. On the electrodynamics…
Author-Year Styles (natbib)
Custom Bibliography Styles
Managing Large Bibliographies
Organizing Your .bib File
Using Multiple .bib Files
String Definitions for Consistency
Advanced Features
Cross-References
Custom Fields and Notes
Special Characters and Formatting
Best Practices
1. Consistent Key Naming
2. Complete Information
Always include:- DOI when available - for reliable access
- URL for online resources
- ISBN for books
- Abstract for searchability
- Keywords for organization
3. Version Control
Troubleshooting
Bibliography not appearing
Bibliography not appearing
Common causes:
- Missing
\bibliography{filename}command - Incorrect filename (don’t include .bib extension)
- Didn’t run BibTeX:
bibtex main - Need additional LaTeX passes
Citation shows as [?] or bold
Citation shows as [?] or bold
Common causes:
- Typo in citation key
- Entry not in .bib file
- BibTeX compilation failed
- Multiple .bib files not all included
Incorrect sorting or formatting
Incorrect sorting or formatting
Common causes:
- Wrong bibliography style
- Missing required fields
- Special characters not escaped
- Verify all required fields are present
- Use
{}to preserve capitalization - Check .bst file compatibility
Encoding and special character issues
Encoding and special character issues
For UTF-8 support:For special characters:
Modern Alternatives
BibLaTeX (Advanced Users)
BibLaTeX is a modern replacement for BibTeX with more features:
- Better Unicode support
- More entry types and fields
- Customizable citation styles
- Multiple bibliographies in one document
Reference Managers
Popular tools that export to BibTeX:- Zotero - Free, open-source
- Mendeley - Free with Elsevier account
- JabRef - BibTeX-specific manager
- EndNote - Commercial, widely used
- Paperpile - Modern web-based
Quick Reference Card
Rendered Output
BibTeX Quick Reference shows three key areas: Essential Commands include \bibliographystyle for setting the style, \bibliography for linking the .bib file, \cite for citations, and \nocite for including uncited references. Compilation Order requires running pdflatex, then bibtex, then pdflatex twice more. Common Styles include plain (numbered, alphabetical), alpha (author-year labels like [Ein05]), abbrv (abbreviated names), unsrt (citation order), and apalike (APA format).
