I need to generate my references separately from the main document (i.e., one pdf with the content and one with the bibliography). I achieved this the following way:

To generate the pdf lacking references, compile the document with the following line \nobibliography{bibfile}. To compile, run pdflatex; bibtex; pdflatex; pdflatex.

To generate the pdf with only references, change the above line to \bibliography{bibfile}, and comment the entire document except this line and the \bibliographystyle line. To comment, I used verbatim (\usepackage{verbatim}) and enclosed everything within \begin{document} and \end{document} with \begin{comment} and \end{comment}, except, as mentioned, the bibliography-pertinent commands. To compile, run pdflatex once.

Is there a simpler way to achieve the same result (one file with references only and one with content only)?

  • Could you tell more information about the way your bibliography is written (style used for instance). If it is only a author-year style, you could easily generate the bibliography file with a nocite{*} instruction before the \printbibliography command (syntax for biblatex use). – Martigan Jan 4 '12 at 16:26
  • Hi Martigan. My bibliography style is unsrt, and references are numerically sorted by their order of appearance. Also, I am using bibtex (not biblatex). – user001 Jan 5 '12 at 13:23
  • Since you have some responses below that seem to answer your question, please consider marking one of them as ‘Accepted’ by clicking on the tickmark below their vote count (see How do you accept an answer?). This shows which answer helped you most, and it assigns reputation points to the author of the answer (and to you!). It's part of this site's idea to identify good questions and answers through upvotes and acceptance of answers. – user36296 Jul 27 '18 at 19:16

Maybe not exactly the solution to your problem, but I give it a shot: You could start the bibliography on a new page and reset the page counter to one


This way you still produce one PDF file with both content and references, but you could separate them into two appropriately page numbered independent files.

  • Thanks vaettchen. That is a very useful suggestion. I could use a linux command line utility to split the document in two afterwards. – user001 Jan 5 '12 at 13:25
  • On linux, the splitting can be achieved with a combination of pdfseparate and pdfsplit. – Alfred M. Dec 16 '15 at 8:12

Lets assume example.tex is your document. In order to generate a document containing only the references used by example.tex you can proceed as follows:

Compile your document using pdflatex, then run bibtex example in order to generate the file example.bbl file. Now create a document references.tex containing something like


Finally compile the above document with pdflatex.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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