LaTeX warning "Please (re)run Biber on the file: main and rerun LaTeX afterwards": cause and fix
biblatex has no current data from Biber for this document. Until Biber has run and LaTeX has run again, citations show the key in bold and the bibliography is empty or outdated. The name in the message is the main file without its extension.
Why it happens
- Biber has not run yet. After the first LaTeX run of a document with
biblatexthis warning is normal. - A
\citewas added or changed since the last Biber run. - BibTeX was run in place of Biber.
biblatexexpects Biber unless it is loaded withbackend=bibtex. - Biber ran and stopped with an error, for example Cannot find 'references.bib'!, or a cited key is missing from the
.bibfile. The warning then comes back after every run.
How to fix it
- Run the sequence LaTeX, Biber, LaTeX, LaTeX. On the command line:
pdflatex main,biber main,pdflatex main,pdflatex main. The example below is the same document in both versions; only the sequence differs. - If your build runs BibTeX, switch its bibliography tool to Biber.
- If the warning stays, read the Biber log, the
.blgfile, and fix the first line markedERRORorWARN.
A document that produces the message
\documentclass{article}
\usepackage{biblatex}
\addbibresource{refs.bib}
\begin{document}
The algorithm is described in \cite{knuth1984}.
\printbibliography
\end{document}File refs.bib:
@book{knuth1984,
author = {Donald E. Knuth},
title = {The TeXbook},
publisher = {Addison-Wesley},
year = {1984}
}The corrected document
\documentclass{article}
\usepackage{biblatex}
\addbibresource{refs.bib}
\begin{document}
The algorithm is described in \cite{knuth1984}.
\printbibliography
\end{document}Both documents were compiled with pdfLaTeX from TeX Live 2023. The first produces the message, the second compiles without an error.
Finding the line in the editor
The editor lists every error and warning of a compile run with file and line. Select an entry and the cursor jumps to that line. See Error list with jump to the line.