> ## Documentation Index
> Fetch the complete documentation index at: https://help.milton.so/llms.txt
> Use this file to discover all available pages before exploring further.

# Cite references

## Cite while you type

1. [Add the reference to your project](https://help.milton.so/collections-projects/projects.md#add-references).
2. In your `.tex` file, type `\cite{`.
3. Pick the reference from the list. Search by key, author, title or year.

   ![Typing \cite\{ in a .tex file lists the project's references](https://mintcdn.com/milton-help/CQbZfUaauwZBJQyI/images/cite-autocomplete.png?fit=max\&auto=format\&n=CQbZfUaauwZBJQyI\&q=85\&s=571d8564c800f96903670834d6107ad1)

## Your bibliography is automatic

Milton writes every reference of the project into `references.bib`, at the top of the project, and keeps it up to date. You don't edit it: change a reference in Milton and the bibliography follows.

If your main file doesn't load a bibliography yet, Milton shows "This file doesn't load a bibliography yet." Click **Add the bibliography** to add it before `\end{document}`.

You can keep your own `.bib` files too, under another name: for example `\bibliography{references,mine}`.

## Citation keys

Each reference has a key like `jacquel2024climate`. Milton uses, in order: a **Citation Key** you set in the reference's **Info**, a `Citation Key:` line from Zotero's Extra field, or a key it generates. Once set, a key doesn't change when you edit the reference.

## Underlined keys

* "*key* is in your library but not in this project.": click **Add to project**.
* "No reference in this project has the key *key*.": check the spelling, or add the reference.
* If two references share a key, the older one keeps it and the newer one becomes *key*-2 in the bibliography. Give one of them its own **Citation Key**.

![An underlined citation key in a .tex file, with the explanation and Add to project](https://mintcdn.com/milton-help/CQbZfUaauwZBJQyI/images/cite-unknown-key.png?fit=max\&auto=format\&n=CQbZfUaauwZBJQyI\&q=85\&s=83aaae519ccd22fff01d71ff4bc39183)

> [!TIP]
>
> The agent can find references that support a sentence and cite them for you. See [Write with the agent](https://help.milton.so/ai/write-with-the-agent.md).


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.