connection.yaml. Run evidence login and the CLI uses the same data connection as your Studio organization.
When to use connection.yaml instead
Add a connection.yaml to your project root only if you need one of these:
- No Evidence Studio account. For example, you self-host Evidence.
- Different credentials. For example, a development database or your own warehouse role instead of your organization’s.
- Offline work. The CLI queries your warehouse directly from your machine, without going through Evidence Studio.
If a
connection.yaml is present, the CLI always uses it, even when you’re logged in and your organization has a connection. If the file is invalid, queries fail with its error; the CLI does not fall back to your organization’s connection. To use your organization’s connection, delete the file.Scaffold with evidence init
The quickest way to create a connection.yaml is to pass --warehouse to evidence init:
connection.yaml in the project root pre-filled with placeholder values, and adds it to .gitignore (the file holds credentials — keep it out of version control).
Fill in the placeholders with your own connection details. If --warehouse is omitted, no connection.yaml is written and the project uses your Evidence Studio organization’s connection after evidence login.
Configuration
- Snowflake
- BigQuery
password, private_key, or private_key_path. Paths (private_key_path) are resolved relative to connection.yaml.See the Snowflake direct connector for the full field reference and how to create a read-only Snowflake user.
