This function is responsible for building .md (or .Rmd) files typically found in the root directory of the package. It will generate the home page from index.Rmd or README.Rmd, then or If none of these are found, it falls back to the description field in DESCRIPTION. It also builds any files found in .github/.

build_home(pkg = ".", override = list(), preview = NA,
  quiet = TRUE)



Path to package.


An optional named list used to temporarily override values in _pkgdown.yml


If TRUE, or && interactive(), will preview freshly generated section in browser.


Set to FALSE to display output of knitr and pandoc. This is useful when debugging.

Images and figures

If you want to include images in your, they must be stored in somewhere in the package so that they can be displayed on the CRAN website. The best place to put them is man/figures. If you are generating figures with R Markdown, make sure you set up fig.path as followed:

```{r, include = FALSE}
  fig.path = "man/figures/"

If you have a package logo, you can include it at the top of your README in a level-one heading:

# pkgdown <img src="man/figures/logo.png" align="right" />

init_site() will also automatically create a favicon.ico from your package logo.

YAML config - home

To tweak the home page, you need a section called home.

The sidebar links are automatically generated by inspecting the URL and BugReports fields of the DESCRIPTION. You can add additional links with a subsection called links, which should contain a list of text + href elements:

  - text: Link text

You can remove the first heading with:

  strip_header: true

YAML config - authors

The "developers" list is populated by the maintainer ("cre"), authors ("aut"), and funder ("fnd") from the DESCRIPTION. You can modify their display on the home page by adding a subsection for authors. The author name should match the value in DESCRIPTION:

    href: ""
    html: "<img src='name-picture.png' height=24>"


ORCID identification numbers are added to author info if they are defined in the DESCRIPTION:

person("Jay", "Hesselberth", role = "aut",
  comment = c(ORCID = "0000-0002-6299-179X")


Status badges are displayed in the sidebar under the section "Dev status". This section is automatically populated if the first paragraph of the homepage consists solely of status badges as linked images.


Users with limited internet connectivity can disable CRAN checks by setting options(pkgdown.internet = FALSE).