Skip to Main Content

Using Overleaf for LaTex

Overleaf is a popular LaTeX/Rich Text-based online collaborative scientific writing and publishing tool for students and researchers. It is designed to make the process of writing, editing, and producing scientific papers quicker and easier for authors.

Citing

In order to cite references,

1. Create a separate bibliography file ending with a .bib extension within your LaTeX project. To do so click on the New File icon on the upper-left corner of the screen.

Then, enter your file name.Your bibliography file must end in .bib. (The default file extension in LaTeX is .text).

screenshot overleaf - new file highlighted. callout to box to change extension from .tex to .bib

Once you create your file, you can add references to it in the BibTeX format.

The easiest way to do that is using Google Scholar. 

1. Click on the Cite link under the article title 

2. click on BibTex

google scholar citation screenshot with circle around the cite link and the BibTex link

 

3. This is the BibTex info from Google Scholar. Copy it. 

google scholar bibtext information

 

4. And paste it into your references.bib overleaf references.bib with the menu that includes paste

 

bibtex pasted into overleaf

1.To cite in text add the command ~ for a nonbreakingspace followed by \cite{}

main.tex with reason to cite

 

2. Go to your references.bib to get the key for the reference as highlighted in the example below.

overleaf references.bib with article key highlighted

3. Back on your main document,

a. Add the article key in the brackets after ~\cite{blum2021prompt}

b. Add a bibliography style, i.e.  \bibliographystyle{plain}

c. Tell the document where to look for the key  i.e.  \bibliography{references.bib}

overleaf linking references

 

4. Click Recompile

Select the references you'd like to add to your file and then click the Share button in the top menu.

screenshot refworks - references selected and arrow to share button

 

Then choose Export References

 

screenshot refworks share button circled, share menu expanded, export references circled.

 

Next, select Format BibTeX and click export.

screenshot refworks share/export references open format selected BibTex

 

Then in Overleaf, click on the upload button at the top of the left hand column.

overleaf highlight upload button

 

The file is uploaded. Copy and Paste the article key (highlighted below)

uploaded export.bib and highlighted article key

 

In your main.tex, cite your source. If using multiple bib files, they are listed in the same command as demonstrated

Bloom demonstrates this process~\cite{blum2021prompt}.
Lucas has a different explanation~\cite{RefWorks:RefID:717-marie2020negotiating}
\bibliographystyle{plain}
\bibliography{references.bib, export.bib}

overleaf multiple bib