Tx · LaTeX & TikZ

How to Customize the Harvard APSR Bibliography Style in LaTeX

Published By the 9to5Science editorial team

At a glance

  1. 1. Identify the style

    Check whether your document uses the harvard package with apsr.bst or another author–date setup.

  2. 2. Choose a method

    Use custom-bib for a new configurable style, or edit a local copy of apsr.bst for small changes.

  3. 3. Use a new name

    Save the customized style as a separate .bst file and select it with \bibliographystyle.

  4. 4. Rebuild the bibliography

    Run LaTeX, BibTeX, then LaTeX twice; check the output against the required APSR conventions.

The Harvard APSR style is a BibTeX .bst file. If your document uses the harvard package, \bibliographystyle{apsr} selects the APSR bibliography formatting supplied with that installation. Changing the output means either editing a style file or generating a different one; there is no general harvard package option that customizes every bibliography detail.

For a few local changes, work on a copy of apsr.bst. For a larger redesign, use custom-bib (also called makebst) to generate a style from a menu of options. These approaches are not interchangeable: makebst generates a style from its own configurable templates; it does not take an existing apsr.bst and convert it into a customized version.

Confirm which style your document uses

Look in the preamble and near the end of your document for the package and bibliography commands. A typical setup is:

\usepackage{harvard}
...
\bibliographystyle{apsr}
\bibliography{references}

The argument apsr names the file apsr.bst (without the extension). Check that the style file is available to your TeX installation. If your project instead uses biblatex, its styles and customization methods are different; do not mix biblatex commands with a BibTeX .bst workflow.

Here is a small complete example using the Harvard package and the APSR BibTeX style. It assumes harvard and apsr.bst are installed:

\begin{filecontents*}{references.bib}
@article{smith2020,
  author  = {Smith, Alex},
  title   = {A Sample Article},
  journal = {Journal of Examples},
  year    = {2020},
  volume  = {12},
  number  = {2},
  pages   = {34--50}
}
\end{filecontents*}

\documentclass{article}
\usepackage{harvard}

\begin{document}
A citation: \cite{smith2020}.

\bibliographystyle{apsr}
\bibliography{references}
\end{document}

Compile with LaTeX, BibTeX, and LaTeX twice. The bibliography style controls how the entry is formatted; the harvard package supplies author–date citation commands and related support.

Make a small change by editing a copy

  1. Locate apsr.bst in your TeX distribution. On TeX Live, kpsewhich apsr.bst often finds it; on MiKTeX, use findtexmf apsr.bst or another MiKTeX file-search method.
  2. Copy it into the project directory and rename the copy, for example myapsr.bst.
  3. Edit the copy, not the installed original. Find the function responsible for the output you want to change and make a narrow modification.
  4. Select the copy with \bibliographystyle{myapsr}.
  5. Re-run BibTeX and LaTeX, then inspect several different entry types in the output.

BibTeX style files use a postfix stack language, not ordinary LaTeX. Functions for author names, titles, punctuation, and entry types can interact, so a change that works for an article may affect books or chapters differently. Keep the original file unchanged and test every entry type used in your bibliography. If you distribute the document, include the modified .bst file with the project.

Generate a style with custom-bib

Install the custom-bib package and run its makebst interactive generator, usually by compiling makebst.tex with LaTeX. Answer its prompts to choose author–date citations and bibliography options, then give the output style a distinct name, such as myapsr. The generator writes a .dbj file; compiling that file produces the .bst style. Use it as \bibliographystyle{myapsr}.

The generated style can approximate the conventions you need, but it will not necessarily reproduce APSR formatting exactly. Compare the result with the journal’s current author guidelines. If the goal is to retain APSR formatting and alter only one detail, editing a local copy of apsr.bst is usually more direct.

Common mistakes

  • Editing the installed style: A TeX update can overwrite your change. Keep a renamed copy in the project instead.
  • Using the wrong style name: Write \bibliographystyle{myapsr} when the file is myapsr.bst; omit the .bst extension.
  • Skipping BibTeX: LaTeX alone will not update the bibliography after a .bst change. Run the full LaTeX–BibTeX–LaTeX–LaTeX sequence.
  • Assuming makebst imports APSR: custom-bib generates a style using its own options. It does not edit or inherit every rule in apsr.bst.
  • Checking only one citation: Bibliography formatting varies by entry type. Test articles, books, and any other types present in your .bib file.

References

  1. The Harvard family of bibliography styles
  2. custom-bib: Generate customized BibTeX bibliography styles

Spotted an error? Send a correction. Read how we write and check articles in our editorial policy.