Assuming one provides the reference, e.g. \cite{historynow1765}, how can I get ConTeXt to display specific fields for that reference, such as the title, publish date, publish location, author's full name, etc.?

E.g., assume the BibTeX file contains this entry:

title={The Stamp Act, 1765: A Spotlight on a Primary Source    by George III},
journal={History Now},
publisher={The Gilder Institute of American History}

Some code like this might call the title information:


Some code like this might call the publisher information:


How can I get this specific information about a source printed in ConTeXt, taking the data from the BibTeX file?

1 Answer 1


Based on https://mailman.ntg.nl/pipermail/ntg-context/2018/090903.html I came up with the following solution, which seems needlessy complicated but it works nonetheless.

The idea is to add separate \cite setups for each individual field using

\startsetups btx:[stylename]:cite:[fieldname]

This enables the syntax \cite[fieldname][refname].

The complicated part is how to convince ConTeXt to actually use these definitions. For this a new style can be created, for example named singlefields. This style can be based on an existing style, such as apa. Following the link above I did the following:

  • copy publ-imp-apa.lua and publ-imp-apa.mkvi to the working directory and rename them as publ-imp-singlefields.lua and publ-imp-singlefields.mkvi. Note that this means that regular \cite and the reference list will be formatted in APA style.
  • in publ-imp-singlefields.mkvi replace all occurrences of apa with singlefields
  • add the \startsetups code (see below)
  • in publ-imp-singlefields.lua, add the extra fields to the misc entry (see below)

Single field code:

\startsetups btx:singlefields:cite:publisher

\startsetups btx:singlefields:cite:journal

\startsetups btx:singlefields:cite:title

\startsetups btx:singlefields:cite:url

Misc entry:

categories.misc = {
    sets = {
        doi  = generic.doi,
    required = {
        -- nothing is really important here
    optional = {
        "author", "withauthor", "translator",
        "title", "subtitle", "file",
        "year", "month",
        "doi", "note",
        "publisher", "journal", "url",




Only title: \cite[title][historynow1765]

Only journal: \cite[journal][historynow1765]

Only publisher: \cite[publisher][historynow1765]

\subject[title=\bf References]




enter image description here

Remark: for some reason this also works out of the box with only adding the fields to the .lua file and not changing the .mkvi file at all, however then the journal and publisher are printed in a monospace font. Besides this, another advantage of the outlined approach is that you can also change the appearance of the bibliography entries, using the setup \startsetups btx:[stylename]:list:[entrytype] syntax.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .