Choose a connection for Snowflake

Overview

This section reviews the connection types and preferred credentials for accessing data in Snowflake.

Access patterns for Snowflake vary based on:

  • Where your code runs, whether Workbench or Connect.

  • The credential method you use. Snowflake supports a variety of credential types. See Select a credential below for the recommended approaches when using Posit Workbench and Posit Connect.

Tip

Once you select a credential approach for both Workbench and Connect, refer to the linked examples for Python and R connection code.

Select a credential

For more information on the choices in the tables below, see this guide’s Getting started section, including: Credential types and Managing data access from development to deployment.

The tables below summarize the recommended credential types for connecting to Snowflake from Workbench and Connect, with links to code examples for both R and Python workflows.

Workbench

Workbench-managed Snowflake credentials are the preferred authentication approach for accessing Snowflake from Workbench.

Workbench manages the user’s credentials and handles token refresh automatically, providing a secure and low-friction experience.

ImportantAdministrator configuration required

Administrators can refer to the Integrate Workbench with Snowflake page in the Workbench Admin Guide for configuration.

The table below summarizes all of the options available for Workbench:

Credential Scope Credential
User Workbench managed credential
(preferred credential)
User Key-pair authentication
One-to-many Key-pair authentication

Connect

Connect OAuth integrations are the preferred authentication approach for accessing Snowflake from Connect. These methods enable secure, short-lived token access without embedding long-lived credentials in published content.

ImportantAdministrator configuration required

Administrators can refer to the Snowflake OAuth Integration page in the Connect Admin Guide for configuration.

The table below summarizes all of the options available for Connect:

Credential Scope Credential
User Connect viewer-level OAuth credentials
(Preferred approach when all viewers have a Snowflake account)
One-to-many Connect service account OAuth
(Preferred approach when viewers do not have Snowflake account)
One-to-many Key-pair authentication