The Living Thing / Notebooks :

Citation management

How a 21st century researcher can imply their ideas are important by presenting them through 20th century infrastructure in the manner of a 19th century gentleman

The genealogy of evidence is important and there are many important ideas about how we could track it, especially with advances in technology; However, this page is not about that propagation of certainty, but rather the shabby proxy, citations in actually-existing academic publishing.

In particular, here I answer for myself: How can I get my journal-ready citations in the outmoded format required by my journals with the most modern possible convenience? Fast-forwarding citations themselves all the way into the state of the 1940s art must fall accomplished by someone else with time.

After trying too many things at great cost of time, I use Zotero. This option is open source, powerful and hackable. It could be more user-friendly; but then the competitors set the bar so low that this is hardly a criticism. Slightly more user-friendly but less hackable is Mendeley, a closed-source reference manager that I will not judge you for using. Since I have no patience for things that cannot be automated, Zotero is an easy winner for me; you may wish to try both.

All other options that I have tried are abysmal and I can say nothing but I told you so if you try them and they give you grief.

What kind of grief?” you ask.


My weapon of choice.

Zotero has, as presaged, an API with which you can both read and write data.

It has an active community around it, and I don’t feel that I am locking my data away forever if I rely upon it. (Of course, you can always try to migrate data around from anything to anything with BibTeX or one fo the XML formats etc, but if you have URLs in there, or consort with foreigners who dare to have diacritics in their names, this usually leads to trouble). I can use the API to make changes that I couldn’t make manually, without worrying about that parsing nonsense. Moreover some other apps, such as Mendeley, already use the Zotero API, so you know that it’s not going to be a community of one playing with it.

Useful hacks

Zotero for your tablet/e-reader

to be evaluated, the currently active clients seem to be

or you you use zotfile to synchronise a folder full of attachments to your tablet. That’s what I do. It’s not perfect, but it’s easy and robust.

pandoc and markdown

See also markdown.

The preferred pandoc-citeproc format seems to be something with an @ sign and/or occasional square brackets

Blah blah [see @heyns_foo_2014, pp. 33-35; also @heyns_bar_2015, ch. 1].
But @heyns_baz_2016 says different things again.

This is how you output it.

# Using the CSL transform
pandoc -F pandoc-citeproc --csl="APA" --bibliography=bibliography.bib \
    -o document.pdf
# or using biblatex and the traditionalist workflow.
pandoc --biblatex --bibliography=bibliography.bib \
    -o document.tex

You will need to set up Preferences>export>Default format to be Better Bibtex citation key quick copy and set Better Bibtex to copy pandoc style.

See the pandoc manual and the pandoc-citeproc manual.

See also the markdown/pandoc page for more on this.

docutils citations

a.k.a. Citations in ReST.

I no longer recommend this. For all the laudable design goals and extensibility of ReST, it’s not where the community is. They are all using markdown.

But if you are keen, the docs say:

Standard ReST citations are supported, with the additional feature that they are “global”, i.e. all citations can be referenced from all files.

I can add:

For your comfort and convenience these citations will be rendered as born-obsolete fugly 1995-esque hard-coded HTML tables that no-one in the entire internet has managed to whip into anything other than an eyesore in a decade of vain struggle.

More resources:

Zotero markup integration

tl;dr. There are many over-engineered solutions. The CSL file one is the simplest I’ve found, and it should additionally work for anything which supports CSL, not only Zotero. This includes Mendeley at the least, and possibly Papers. Others?

Anyway, if you want a more fragile but fancier solution, there are other options below.

Render using a CSL style file.

CSL is a citation rendering mini-language used by modern journals and software to express house style. And you can use it too.

Screencap of Zotero
Screencap of Zotero

This is a slightly weird way to get plain-text citations out, since it’s designed for rich formatting etc, but it is robust ad simple. There is a CSL editor online so this is easy-ish.

CSL has a citation-label variable, but it doesn’t correspond to the bibtex keys generated by BBT, which is unsatisfactory.

Better BibTex

a.k.a BBT.

Better bibtex makes all the BibTex stuff in Zotero much smoother, and since bibtex also integrates with markdown via pandoc, this is a double win.

Here are some citation key format strings for bibtex.


I currently use this one


I am fond of the following biblatex export exclusions:


Atom citation picker

For Atom+Zotero+Markdown, you could try zotero citation, which adds a citation picker to the atom editor. References look like

[\(Heyns, 2014\)](#@heyns2014)
[\(Heyns, 2014\)]([email protected],heyns2015)

The bibliography is rendered in either pandoc-YAML or plaintext format at

[#bibliography]: #

I don’t bother; BetterBibtex works fine for my needs.

They are rendered in the output by an in-built pandoc filter, which is installed separately.

Dynamic bibliography file generation

Erik Hetzner’s zotxt can avoid the need to create bibfiles, rendering bibliographies directly by querying the zotero app, rather than manually rendering an intermediate file. Note that Better BibTex also does this, and even more flexibly, and so may wish to use it.


Oh, BibTeX

None of that faffing about is useful if you are working with academics, who don’t regard words on the internet as a real thing. Your words must be behind a paywall where no-one can read them to count as significant. Moreover, they must have been rendered harder to analyse by running them through LaTeX, and obfuscating them into a PDF, which probably also entails using BibTeX to do the citation stuff.

If you are starting from Zotero, you can use Better BibTeX to make this less painful.

To manage annoying BibTeX problems from BibTeX files themselves algorithmically I use bibtool.

BibTeX is ancient and has accreted deep strata of fossilised rules, but it does work if you move very carefully and don’t touch anything. Imitate your predecessors and the gods will reward you.


a.k.a. biber, because it is broken into a couple of distinct packages. It looks similar to BibTeX but is better in various ways, except in that it is not supported by many moribund journals/conferences who think these foreigners will despair of their disconcerting languages.

As such, it is a low key upgrade from the winding steeplechase of character set errors that is BibTeX. It can handle non-english names and URLs, bringing it up to speed with 1999. You often need to use bib styles made by passionate bibliography rendering fans, e.g. here is an IEEE-like one.

To mention

Jabref, bibdesk, biblatex vs bibtex vs biber, character set sadness.

Past traumas

There have been various other options such as Papers (meh) and Sente (defunct due to being crappy) and (sigh) Endnote. I won’t link or refer to those further here, for the reason that I’ve already lost too much data that way, and I don’t intend to lose more. Since all citation software is, basically, awful, it is even more important that whichever application you choose, it is one that you can get your data out of it when you find a less awful option. But the one that is best at letting you keep all your citations even if you ditch it, is Zotero. Also it’s probably the least awful.

Still, if you’re unswayably dedicated to trying other things for yourself, here is my advice: For any closed-source software my advice is the same – Try and see how well you can get data in and out, en masse, because that’s what you’ll have to do if the company goes bankrupt or gets bought by Google and shut down, or by Yahoo and accidentally set on fire, or by Facebook and you are only allowed to use it if you click on ads promoting sports shoes for 18 minutes out of every hour.

All the alternatives apart from Mendeley and Zotero have failed the test of preserving my precious data when I exported it to a different software package, so using those other packages is putting my work in the uncaring hands of an unaccountable third party. To actually extract my data from Sente, for example, I had to burn a whole working week turning their malformed markup into valid XML, (which is a specialty that I don’t care about and no-one should ever need to care about) and I still couldn’t work out how to parse some of it. Then many other things went wrong. Also, Mendeley started behaving suspiciously since they got bought by Elsevier

If you mostly care about LaTeX (which decision is constrained by the lowest common denominator amongst your collaborators, and probably not available to promiscuous authors) you might be able to survive on Bibdesk or jabref or just editing a plain Bib(La)TeX file, but I for one could not bear to give up the browser integration of Zotero, which has saved innumerable hours of painstaking pointless typing.

See also text editors, academic writing workflow.

TODO: complain about the entire structure of citations in the electronic age (keep it short though, because everyone is tired of complaining about it, and at least it’s better than the general howling void of unsourced internet media.)

TODO: apologise for accidentally complaining at length despite my stated aim of keeping it short.