Quarto Projects

Quarto projects

Quarto projects are directories that provide:

  • A way to render all or some of the files in a directory with a single command (e.g. quarto render myproject).
  • A way to share YAML configuration across multiple documents.
  • The ability to redirect output artifacts to another directory.
  • The ability to freeze rendered output (i.e. don’t re-execute documents unless they have changed).

Quarto projects

Some formats must be created within a Quarto project:

  • Websites
  • Blogs
  • Books

Anatomy of a Quarto project

A Quarto Project is a directory that contains a file called _quarto.yml.


This is a Quarto Project.

my-folder/
├── _quarto.yml
├── my-document.ipynb

This is not.

my-folder/
├── my-document.ipynb

_quarto.yml

A YAML file with particular keys and values that Quarto recognizes. Unrecognized keys are ignored.

_quarto.yml
project:
  title: "Quarto---To Tell Your Story with Data"

_quarto.yml

A YAML file with particular keys and values that Quarto recognizes. Unrecognized keys are ignored.

_quarto.yml
project:
  type: website
  output-dir: docs

website:
  page-navigation: true
  title: "Quarto---To Tell Your Story with Data"
  description: "Government Advances in Statistical Programming (GASP) 2025"

  repo-url: https://github.com/ivelasq/2025-06-26_intro_to_quarto
  repo-actions: [edit, issue]

  open-graph: true

  sidebar:
    background: "#2b3d5b"
    logo: "images/fcsm-logo-no-text.png"
    pinned: true
    align: center
    style: docked
    search: true
    collapse-level: 2
    contents:
      - href: index.qmd
        text: Home
      - href: 00-introduction/index.qmd
        text: Introduction
      - href: 01-documents/index.qmd
        text: Documents
      - href: 02-projects/index.qmd
        text: Projects
      - href: 03-theming/index.qmd
        text: Theming
      - href: 04-publishing/index.qmd
        text: Publishing
        
  page-footer:
    right: "This page is built with ❤️ and [Quarto](https://quarto.org/)."
    left: "© Copyright 2025, Isabella Velásquez"
    background: "#D1D9E3"

format:
  html:
    theme:
      light: [brand, style.scss]
    linkcolor: "#991b1f"
    toc: true
    code-copy: true
    code-overflow: wrap
    mainfont: "Open Sans"

execute:
  freeze: auto
  echo: true

Freeze

You can use the freeze option to denote that computational documents should never be re-rendered during a global project render, or alternatively only be re-rendered when their source file changes:

_quarto.yml
execute:
  freeze: true  # never re-render during project render


_quarto.yml
execute:
  freeze: auto  # re-render only when source changes

Your turn

  • In your folder, convert the document into a project by running:
Terminal
quarto create project
  • For Type, select website.
  • For Directory, type ..
  • For Title, give it a title related to dams.

Quarto will create several files, including _quarto.yml.

  • Open _quarto.yml.

Your turn

  • Add final-py.qmd or final-r.qmd under Home and give it the text Report:
_quarto.yml
navbar:
  left:
    - href: index.qmd
      text: Home
    - href: final-r.qmd
      text: Report
  • Open about.qmd and add some information about yourself. Feel free to edit the YAML.
  • Render the project, then explore your new website!
05:00