# Make the author names, the year, and the journal's volume number bold with biblatex/biber

I'm using biber with the following options:

\usepackage[backend=biber,style=authoryear,maxbibnames=9,maxcitenames=2,uniquelist=false,autocite=inline]{biblatex}


At the end of my tex document, I print the reference list:

\printbibliography[title={References}]


The journal editor required me to change the reference list such that the author names, the year, and the journal's volume number are bold. I couldn't find a clear way to do this. Is this possible? If so, any clue on how to do it?

• It should be possible. Could you post a complete, yet minimal, code that we can play with? – Bernard Jun 25 '19 at 21:12
• This isn't too hard to do. But the standard authoryear style formats the volume and issue number as vol.iss (e.g. 14.3). So do you want only the volume bold, or both? – Alan Munn Jun 25 '19 at 22:31

Using the biblatex-ext styles (which provide drop-in replacements for the standard styles), we can easiy customize both the names the date format. (See How to (properly) remove the parentheses around the year in authoryear style? (v3)). Thanks to moewe for pointing out the simpler name code too (and for writing biblatex-ext).

\documentclass{article}
\usepackage[style=ext-authoryear,maxbibnames=9,maxcitenames=2,uniquelist=false,autocite=inline]{biblatex}

\DeclareNameAlias{sortname}{family-given}
\DeclareNameWrapperFormat{sortname}{\mkbibbold{#1}}
\DeclareFieldFormat{biblabeldate}{\mkbibparens{\mkbibbold{#1}}}
\DeclareFieldFormat[article,periodical]{volume}{\mkbibbold{#1}}

\begin{document}
\autocite{herrmann,doody}

\printbibliography
\end{document}


If you want to do this using the apa style (which I don't recommend) the following code needs to be used:

\documentclass{article}
\usepackage[style=apa,maxbibnames=9,maxcitenames=2,uniquelist=false,autocite=inline]{biblatex}

\DeclareNameFormat{apaauthor}{\mkbibbold{%
\ifthenelse{\value{listcount}=\maxprtauth\AND\value{listcount}<\value{listtotal}}
{\ifthenelse{\value{listcount}>\maxprtauth\AND\value{listcount}<\value{listtotal}}
{}
{\iffieldannotation{uncertain}
{\mkbibbrackets{\usebibmacro{name:apa:family-given}%
{\namepartfamily}%
{\namepartgiven}%
{\namepartgiveni}%
{\namepartprefix}%
{\namepartsuffix}?}}
{\usebibmacro{name:apa:family-given}%
{\namepartfamily}%
{\namepartgiven}%
{\namepartgiveni}%
{\namepartprefix}%
{\namepartsuffix}}}}%
\ifthenelse{\value{listcount}=\value{listtotal}}%
{\ifmorenames{\printdelim{andothersdelim}\bibstring{andothers}}{}}{}}}

\ifboolexpr{ test {\ifdatecirca} or test {\ifdateuncertain} }
{\printtext{\mkbibbrackets{\mkbibbold{#1}}}}
{\printtext{\mkbibparens{\mkbibbold{#1}}}}}

\DeclareFieldFormat[article,periodical]{volume}{\mkbibbold{#1}}

\begin{document}
\autocite{herrmann,doody}

\printbibliography
\end{document}


• Thanks. Same here, I couldn't get the dates in bold. Strange. – hsnm Jun 26 '19 at 3:06
• @hsnm Your example used authoryear as the style. If you are using apa as the style, then the question is a lot different. apa is a complex style that is not designed to be modified, since it implements the very specific APA requirements. – Alan Munn Jun 26 '19 at 3:10
• Changing the date did not work in authoryear. – hsnm Jun 26 '19 at 3:26
• @hsnm You need to load ext-authoryear not authoryear. – Alan Munn Jun 26 '19 at 3:31
• Really appreciate the help, but my compiler didn't find ext-authoryear. – hsnm Jun 26 '19 at 3:39

You have to add some code to change the wanted author names, year and volume number to be bold (see marking <===== for important code with explanaition for its use) in your preamble:

\DeclareFieldFormat{date}{\mkbibbold{#1}} % <=========================== date
\DeclareFieldFormat[article,periodical]{volume}{\mkbibbold{#1}} % <===== volume
\DeclareNameAlias{sortname}{first-last-bold}
\DeclareNameFormat{first-last-bold}{\mkbibbold{% <====================== name
\ifgiveninits
{\usebibmacro{name:given-family}{\namepartfamily}{\namepartgiveni}{\namepartprefix}{\namepartsuffix}}
{\usebibmacro{name:given-family}{\namepartfamily}{\namepartgiven}{\namepartprefix}{\namepartsuffix}}%
\usebibmacro{name:andothers}}}


\RequirePackage{filecontents}
\begin{filecontents*}{\jobname.bib}
@article{ahlswede2000network,
title={Network information flow},
author={Ahlswede, Rudolf and Cai, Ning and Li, Shuo-Yen Robert and
Yeung, Raymond W},
journal={Information Theory, IEEE Transactions on},
volume={46},
number={4},
pages={1204--1216},
year={2000},
publisher={IEEE},
}
@article{einstein,
author =       "Albert Einstein",
title =        "{Zur Elektrodynamik bewegter K{\"o}rper}. ({German})
[{On} the electrodynamics of moving bodies]",
journal =      "Annalen der Physik",
volume =       "322",
number =       "10",
pages =        "891--921",
year =         "1905",
DOI =          "http://dx.doi.org/10.1002/andp.19053221004",
keywords =     "physics",
}
@book{dirac,
title={The Principles of Quantum Mechanics},
isbn={9780198520115},
series={International series of monographs on physics},
year={1981},
publisher={Clarendon Press},
keywords = {physics},
}
\end{filecontents*}

\documentclass{article}

\usepackage[%
backend=biber,
style=authoryear,
maxbibnames=9,
maxcitenames=2,
uniquelist=false,
autocite=inline
]{biblatex}

\DeclareFieldFormat{date}{\mkbibbold{#1}} % <=========================== date
\DeclareFieldFormat[article,periodical]{volume}{\mkbibbold{#1}} % <===== volume
\DeclareNameAlias{sortname}{first-last-bold}
\DeclareNameFormat{first-last-bold}{\mkbibbold{% <====================== name
\ifgiveninits
{\usebibmacro{name:given-family}{\namepartfamily}{\namepartgiveni}{\namepartprefix}{\namepartsuffix}}
{\usebibmacro{name:given-family}{\namepartfamily}{\namepartgiven}{\namepartprefix}{\namepartsuffix}}%
\usebibmacro{name:andothers}}}

\begin{document}

Some \autocite{einstein} text \cite{einstein}.
\parencite[I.6.2]{dirac}.

\nocite{*}
\printbibliography[title={References}]

\end{document}


you get the result:

• The default author/year name format is Family-Given, not Given-Family. – Alan Munn Jun 25 '19 at 23:48
• @AlanMunn Intresting, I got no error message or warning, Not with given-family, nor with family-given or Family-Given, but always the same resulting bibliography. Bug or feature in biblatex? – Mensch Jun 26 '19 at 0:05
• You need to change the definition you've given to first-last-bold. – Alan Munn Jun 26 '19 at 0:39
• @AlanMunn ?? what should be changed? It compiles withour error message or warning on my current MiKTeX ... – Mensch Jun 26 '19 at 0:51
• Thanks. It works well, except that I had to use \DeclareFieldFormat{date}{\bfseries{#1}} instead (no idea why). I tried your code with style=apa, but I did not get bold names, date, nor volume. What would be different with apa? – hsnm Jun 26 '19 at 3:03