The Citation File Format project (Druskat et al. 2021) defines a standardized format for providing software or datasets citation metadata in plaintext files that are easy to read by both humans and machines.
This metadata format is being adopted by GitHub as the primary format for its built-in citation support (GitHub 2021). Other leading archives for scientific software, including Zenodo and Zotero (Druskat 2021), have also included support for CITATION.cff files in their GitHub integration.
The cffr package provides utilities to generate and validate these CITATION.cff files automatically for R (R Core Team 2025) packages by parsing the DESCRIPTION file and the native R citation file. The package also includes utilities and examples for parsing components such as persons and additional citations, as well as several vignettes that illustrate both the basic usage of the package and more technical details about the metadata extraction process.
Citation of research software in research projects is often omitted (Salmon, Chamberlain, and Ram 2021). One reason software is not cited is the lack of clear citation information from package developers.
Some of the main reasons for citing software used on research are:
CITATION.cff files provide clear citation rules for software. The format is easy to read by humans and can also be parsed by appropriate software. GitHub’s adoption of this format sends a strong message that research software is worthy of citation and therefore deserves credit.
The cffr package allows R software developers to create CITATION.cff files from metadata already included in the package. It also includes validation tools via the jsonvalidate package (FitzJohn et al. 2025), which allow developers to assess the validity of the file created using the latest CFF schema.json.
I would like to thank Carl Boettiger, Maëlle Salmon and the rest of the contributors of the codemetar package (Boettiger and Salmon 2026). This package was the primary inspiration for developing cffr and shares a common goal of increasing awareness of the efforts of software developers.
I would also like to thank João Martins and Scott Chamberlain for thorough reviews that helped improve the package and documentation, and Emily Riederer for handling the review process.
Hernangómez, D., (2021). cffr: Generate Citation File Format Metadata for R Packages. Journal of Open Source Software, 6(67), 3900, https://doi.org/10.21105/joss.03900
@article{hernangomez2021,
doi = {10.21105/joss.03900},
url = {https://doi.org/10.21105/joss.03900},
year = {2021},
publisher = {The Open Journal},
volume = {6},
number = {67},
pages = {3900},
author = {Diego Hernangómez},
title = {cffr: Generate Citation File Format Metadata for R Packages},
journal = {Journal of Open Source Software}
}