Posit Connect Cloud

NotePre-release Feature

This feature is new in the upcoming Quarto 1.9 release. To use the feature now, you’ll need to download and install the Quarto pre-release.

Overview

Posit Connect Cloud is an online platform from Posit for deploying and sharing data applications and documents. Use Posit Connect Cloud when you want a hosted service for publishing Quarto documents and websites without managing your own infrastructure. Posit Connect Cloud includes a free tier that allows unlimited publishing of static documents.

Note

Looking for self-hosted deployment within your organization? See Posit Connect.

There are several ways to publish Quarto content to Posit Connect Cloud:

  1. Use the quarto publish command to publish locally rendered static content.

  2. Publish source content from a GitHub repository. The source is rendered by Posit Connect Cloud, and redeployed automatically when content is pushed to the repository.

  3. Publish source content from an IDE (Positron, VS Code, or RStudio).

  4. Script the quarto publish command to publish from a Continuous Integration (CI) service.

Each of these options is covered below. If you are just getting started, we recommend using the first approach, quarto publish.

Publish Command

The quarto publish command is the easiest way to publish locally rendered content. From the directory where your project is located, execute the quarto publish command for Posit Connect Cloud:

Terminal
quarto publish posit-connect-cloud

If you haven’t published to Posit Connect Cloud before, the publish command will prompt you to authenticate.

A browser will open to authenticate using your Posit account:

Terminal
$ quarto publish posit-connect-cloud
? Authorize (Y/n)  ❯ In order to publish to Posit Connect Cloud you need to authorize your account. Please be sure you are logged into the correct Posit Connect Cloud account in your default web browser, then press Enter or ‘Y’ to authorize.

After confirming that you want to publish, your content will be rendered and deployed, and then a browser opened to view your site.

_publish.yml

The _publish.yml file is used to specify the publishing destination. This file is automatically created (or updated) whenever you execute the quarto publish command, and is located within the project or document directory.

The service, id, and URL of the published content is specified in _publish.yml. For example:

- source: project
  posit-connect-cloud:
    - id: "5f3abafe-68f9-4c1d-835b-9d668b892001"
      url: "https://connect.posit.cloud/content/5f3abafe-68f9-4c1d-835b-9d668b892001"

If you have an existing Posit Connect Cloud site that you want to publish to, you should manually create a _publish.yml file that looks like the example above, but with the appropriate id and url values for your site.

Account information is not stored in _publish.yml, so it is suitable for checking in to version control and being shared by multiple publishers.

Options

You can customize the behavior of quarto publish by providing the following command line options:

Option Behavior
--no-prompt Do not prompt to confirm publish actions.
--no-browser Do not open a browser after publish.
--no-render Do not re-render prior to publish

To publish a document rather than a website or book, provide the path to the document:

Terminal
quarto publish posit-connect-cloud document.qmd

Multiple Accounts

If you have multiple Posit accounts, you’ll be prompted to choose which account to publish with. You can manage stored accounts using:

Terminal
quarto publish accounts

Publish from GitHub

Posit Connect Cloud can publish directly from a GitHub repository. When you push changes to the connected branch, Posit Connect Cloud automatically re-renders and redeploys your content. This is ideal for scheduled reports and collaborative projects.

See the Posit Connect Cloud documentation on Publishing from GitHub for setup instructions and details.

Publish from your IDE

You can publish source content directly from your editor using:

  • Posit Publisher — A VS Code / Positron extension for deploying content to Posit Connect Cloud. Pre-installed in Positron; available from the VS Code Marketplace for VS Code.

  • rsconnect — The rsconnect R package can deploy R content programmatically from RStudio or any R session.

See the Posit Connect Cloud documentation on Publishing from an IDE for setup instructions and details.

Continuous Integration

You can publish to Posit Connect Cloud from a CI service by scripting the quarto publish command with environment variables for authentication. These tokens are generated during the interactive quarto publish flow and stored locally — use quarto publish accounts to view stored credentials.

Variable Description
POSIT_CONNECT_CLOUD_ACCESS_TOKEN OAuth access token for authentication (required).
POSIT_CONNECT_CLOUD_REFRESH_TOKEN OAuth refresh token (required).
POSIT_CONNECT_CLOUD_ACCOUNT_ID Account ID to publish with (required if you have multiple accounts).
Terminal
export POSIT_CONNECT_CLOUD_ACCESS_TOKEN="..."
export POSIT_CONNECT_CLOUD_REFRESH_TOKEN="..."
quarto publish posit-connect-cloud --no-prompt --no-browser

See the article on Publishing with CI for additional details on non-interactive use of quarto publish.