Skip to content

Connecting to Snowflake

12 min read · Updated 9 Nov 2026

This guide connects Astrato to a Snowflake account. When you finish, the connection appears in Data & AI → Data Connections and you can build a semantic layer on it. The steps are the same form described in Data connections; this page adds what is specific to Snowflake. It describes the current lobby, although it keeps its Help Center address.

Before you start: check each of these. Most failed validations come from one of them.

  • Astrato permission. You need a workspace role that can create data connections: Owner, Admin or Creator. The account menu, your profile picture at the top right, shows your role under your name. If New connection is missing from Data & AI → Data Connections, ask a workspace administrator (see How access works).
  • Your account URL. In Snowsight, open the account menu and use Copy account URL. Either form works: ab12345.eu-west-2.aws.snowflakecomputing.com (account locator) or myorg-myaccount.snowflakecomputing.com (organization and account name). A leading https:// is accepted.
  • A Snowflake user and role that can use a warehouse and read the data you want. See Role and privileges.
  • Network access. If your Snowflake account or user has a network policy, Astrato’s addresses must be allowed. See Network policy.
  • A credential for the authentication method you choose. See Choose an authentication method. If you are not a Snowflake administrator, see If you are not a Snowflake administrator.

If the account URL you copied is rejected, run this in a Snowflake worksheet. It lists the host names your account answers on; the SNOWFLAKE_DEPLOYMENT and SNOWFLAKE_DEPLOYMENT_REGIONLESS rows are the two forms of the account URL.

-- List the host names for this Snowflake account
SELECT t.value:type::varchar AS type,
t.value:host::varchar AS host,
t.value:port AS port
FROM TABLE(FLATTEN(input => PARSE_JSON(SYSTEM$ALLOWLIST()))) AS t
WHERE t.value:type::varchar LIKE 'SNOWFLAKE%';

The Authentication section offers three methods, in this order:

Method Choose it when What you enter
Private key (Recommended) You connect as a service user, or your account enforces multi-factor authentication. Snowflake is moving accounts away from passwords. Username and Private key, then Account URL
Sign in with Snowflake Each person should query with their own Snowflake identity. An administrator first sets up an access integration. An OAuth connection, then Sign in
Password (legacy) You are testing, or your account still allows password sign-in for this user. Users with multi-factor authentication cannot use it. Username and Password, then Account URL

You do not need a key pair already. With Private key (Recommended) selected, Generate key pair beside the field creates one in your browser and fills in the private key. Below it, Astrato shows the statement to run in Snowflake, headed “Run this in Snowflake to accept the key, then validate.”, with a Copy button. The statement has this shape:

ALTER USER <username> SET RSA_PUBLIC_KEY_2='<public key>'

The New Snowflake connection panel with Private key (Recommended) chosen, Username ASTRATO_SERVICE, a generated private key, and below it a box headed Run this in Snowflake to accept the key, then validate, holding an ALTER USER ASTRATO_SERVICE SET RSA_PUBLIC_KEY_2 statement and a Copy button, above the Account URL field

It uses Snowflake’s second key slot, so a key already in the first slot keeps working. Running it needs a role that can alter the user, such as SECURITYADMIN. The statement names the Username you entered and updates if you change it. If your browser cannot generate the key, Astrato says so; paste an existing private key instead. For a full service-user setup, see Snowflake key-pair authentication and Snowflake MFA.

You can still use Private key (Recommended) without a role that can alter users. The statement Astrato shows holds only the public half of the key, which is safe to send to someone else; the private key stays in your browser until you validate.

  1. Fill in Username, select Generate key pair, and select Copy beside the statement.
  2. Send the statement to whoever administers Snowflake users, and ask them to run it. If the user does not exist yet, ask them to create it with the role in Role and privileges at the same time.
  3. Keep the New Snowflake connection panel open while you wait. The generated private key exists only in that panel: if you close it, generate a new pair and send the new statement.
  4. When they confirm, paste the Account URL and select Validate Connection.

If your account has a network policy, the same person can add Astrato’s addresses; see Network policy. If your workspace already has a verified Snowflake access integration, Sign in with Snowflake needs no key at all: you sign in as yourself.

  1. Open Data & AI → Data Connections and select New connection.

    The New connection panel beside the Data Connections list, with a Source grid of Snowflake, Google BigQuery, ClickHouse, Databricks, Amazon Redshift, Supabase, DuckDB, Dremio and PostgreSQL tiles, and Google Sheets and Demo data greyed out

  2. Select Snowflake. The panel title changes to New Snowflake connection.

  3. Under Authentication, choose a method from the list (see Choose an authentication method) and fill in its fields. For Sign in with Snowflake, choose the OAuth connection and select Sign in, then complete sign-in in the window that opens.

    The New Snowflake connection panel after selecting Private key: Username and Private key fields under Authentication, then Account URL and Deployment Region under Connection details, with the Validate Connection button

  4. Under Connection details, paste the Account URL. If your workspace shows Deployment Region, you can leave it unset for now. Once selected, validation and source discovery go through that region, and a Data App cannot be published on this connection until one is selected. See Choose a Deployment Region.

  5. Select Validate Connection. It stays unavailable while a required field is empty, and the form lists those fields after “Still needed:”.

    The New Snowflake connection panel with Private key (Recommended), Username ASTRATO_SERVICE and a generated key filled in, the Account URL field empty showing its placeholder, and below the unavailable Validate Connection button the hint Still needed: Account URL.

  6. With Private key (Recommended) or Password (legacy), choose a Warehouse under Session; if the user has a default warehouse, it is already chosen. The warehouse is required before you can save. Role is optional; if you do not choose one, the user’s default role is used.

    With Sign in with Snowflake, Role and Warehouse both read User default and cannot be changed: each person who uses the connection queries with their own Snowflake user’s default role and warehouse. To set them for everyone instead, select Advanced beside the Session heading and choose them. Clearing Advanced returns both to User default.

  7. Under Data to use, choose the Database. Schema stays at (Default) until the connection is saved; you can choose one in step 10.

    The New Snowflake connection panel after validating: a Validation result reading Connected to Snowflake in 140 ms, Session with Role left empty and Warehouse ANALYTICS_WH, Data to use with Database SALES and Schema at (Default) until the connection is saved, and Connection name Snowflake above the Save connection button

  8. Under Name, the suggested Connection name is Snowflake. Change it to something people will recognise, such as the database’s name.

  9. Select Save connection.

  10. The panel shows Connection created with “Choose a schema now, or finish to use this connection.” Choose a schema or leave it as Choose later, then select Finish.

  • After step 5, a Validation result section says “Connected to Snowflake in n ms.”, and the Session and Data to use lists fill in. Before that, they read “Available once the connection validates.” With Sign in with Snowflake, Session stays at User default unless you select Advanced.
  • The Database list shows only the databases the user’s role can see. If it is empty, the role has no access; see Role and privileges.
  • After Finish, the connection is in the Data Connections list with its name, source, connection details and Deployment Region.

To confirm that the connection can read your tables before you model them, start an empty semantic layer on it and open Add → Tables & Views; see Check that it works.

If validation fails, see When a data connection will not validate.

Astrato reads Snowflake with the role you pick under Session (or the user’s default role). That role needs to use a warehouse and read the databases, schemas and tables you will model. This is a typical read-only setup in Snowflake’s own access control; rename the objects to match yours and follow your own security policy:

USE ROLE SECURITYADMIN;
CREATE ROLE IF NOT EXISTS ASTRATO_READER;
GRANT USAGE ON WAREHOUSE ANALYTICS_WH TO ROLE ASTRATO_READER;
GRANT USAGE ON DATABASE SALES TO ROLE ASTRATO_READER;
GRANT USAGE ON ALL SCHEMAS IN DATABASE SALES TO ROLE ASTRATO_READER;
GRANT SELECT ON ALL TABLES IN DATABASE SALES TO ROLE ASTRATO_READER;
GRANT SELECT ON ALL VIEWS IN DATABASE SALES TO ROLE ASTRATO_READER;
GRANT ROLE ASTRATO_READER TO USER ASTRATO_SERVICE;
ALTER USER ASTRATO_SERVICE SET DEFAULT_ROLE = ASTRATO_READER DEFAULT_WAREHOUSE = ANALYTICS_WH;

ALL TABLES and ALL VIEWS cover only objects that exist now. For tables created later, add GRANT SELECT ON FUTURE TABLES IN DATABASE SALES TO ROLE ASTRATO_READER; and the same for views.

Writing data back from Astrato needs more than SELECT; see Writeback.

If your Snowflake account or the connecting user has a network policy, Snowflake refuses connections from addresses that are not on it, and Validate Connection fails.

  • With a Deployment Region selected, the form names that region’s addresses under the region, as “Allow traffic from … at your database.” Allow those addresses.
  • Without a Deployment Region (Legacy / not selected), allow Astrato’s addresses 34.142.11.11 and 34.142.68.232.

Changing a network policy needs a Snowflake administrator. If that is not you, send them the addresses above. To add them, they edit the policy, for example with ALTER NETWORK POLICY <policy> SET ALLOWED_IP_LIST = (...). SET replaces the whole list, so include the addresses already on it. For a private network path instead, see AWS PrivateLink.

Sign in with Snowflake needs an access integration: a Snowflake OAuth security integration, registered in Astrato. A workspace owner or administrator sets it up once; after that, each person who creates or uses the connection signs in to Snowflake as themselves.

Before you start: you need the Owner or Administrator workspace role in Astrato, and a Snowflake role that can create security integrations, such as ACCOUNTADMIN.

  1. In Astrato, open Administration → Enterprise Connection, select the Access integrations tab and select Add integration.

  2. Under Select a Data provider, choose Snowflake from the Provider list. The Configuration tab lists what the Snowflake side needs: grant type authorization code, a Callback URL ending in /auth/proxy/connection/snowflake-verify/callback, and the scope session:role-any. Copy the Callback URL exactly as shown; it names your Astrato host.

    The Add integration dialog with Snowflake chosen under Select a Data provider, its Configuration tab listing grant type authorization code, the Callback URL https://app.astrato.io/auth/proxy/connection/snowflake-verify/callback and the scope session, and a Continue to Setup button

  3. In a Snowflake worksheet, create the security integration with that callback URL:

    CREATE SECURITY INTEGRATION ASTRATO_OAUTH
    TYPE = OAUTH
    ENABLED = TRUE
    OAUTH_CLIENT = CUSTOM
    OAUTH_CLIENT_TYPE = 'CONFIDENTIAL'
    OAUTH_REDIRECT_URI = '<Callback URL from Astrato>'
    OAUTH_ISSUE_REFRESH_TOKENS = TRUE
    OAUTH_REFRESH_TOKEN_VALIDITY = 7776000;

    Refresh tokens let Astrato renew each person’s short-lived access token; 7776000 seconds is 90 days, after which people sign in again. Follow your own policy for these values and for which roles to block.

  4. Read the client ID and secret from Snowflake. DESC SECURITY INTEGRATION ASTRATO_OAUTH; shows OAUTH_CLIENT_ID, and SELECT SYSTEM$SHOW_OAUTH_CLIENT_SECRETS('ASTRATO_OAUTH'); returns the client secret.

  5. Back in Astrato, select Continue to Setup and fill in:

    • Integration name: the name people will see when they choose an OAuth connection, such as Snowflake production.
    • Snowflake account URL: your account URL with https://, such as https://ab12345.eu-west-2.aws.snowflakecomputing.com.
    • Client ID and Client secret: the values from step 4.

    The Setup tab of the Add integration dialog for Snowflake, with Integration name Snowflake production, Snowflake account URL, Client ID and a masked Client secret filled in, and Cancel and Create buttons

  6. Select Create. The new integration opens, reading “Snowflake is not enabled”.

  7. Under Verification, select Verify connection and sign in to Snowflake in the window that opens. When sign-in succeeds, the status changes to “Snowflake is enabled”. Verify the integration before using it to access data.

    The properties panel of the Snowflake production access integration, reading Snowflake is not enabled, with a Verification section saying Verify this connection before using it to access data and a Verify connection button, above the General fields

People creating a connection then choose Sign in with Snowflake, pick this integration under OAuth connection and select Sign in; see step 3 of Create the connection. The hint below the list says whether they are already authorized, need to sign in, or need to sign in again because authorization has expired.

To change the integration later, select Edit on its row in Access integrations. The stored client secret is never shown: select Replace secret to enter a new one, then select Save. While the integration is not yet verified, Verify connection stays unavailable until you save your changes.

What happens Likely cause What to do
Validation fails straight away Wrong Account URL, username or credential Copy the account URL again from Snowsight, check the username, and re-enter the credential
Validation fails with a password that works in Snowsight The user has multi-factor authentication, which Password (legacy) cannot complete Switch to Private key (Recommended)
Validation fails with a generated key The ALTER USER statement was not run, or was run for another user Run the statement shown under the private key with a role that can alter the user, then validate again
Validation fails only from your network A Snowflake network policy blocks Astrato Allow the addresses in Network policy
“This credential reported no databases. Check its grants, or validate again.” The role has no USAGE on any database Grant the privileges in Role and privileges, or choose another Role
Save connection stays unavailable No Warehouse or Database chosen, or the role cannot use a warehouse Choose both; if the warehouse list is empty, grant USAGE on a warehouse to the role
“No configured OAuth connections.” No Snowflake access integration is set up in Astrato Ask a workspace administrator to set one up, or use Private key (Recommended)

The full list of messages, for every source, is in When a data connection will not validate.