dbt Cloud CLI: dbt_cloud.yml not found / not authenticated
Fixes the dbt Cloud CLI failing because dbt_cloud.yml is missing or its credentials are rejected. Use when the dbt Cloud CLI (dbt-cloud) errors about a missing config file or says you are not authenticated before running. Generates a valid dbt_cloud.yml from the dbt Cloud UI and places it where the CLI looks. Not for dbt Core profiles.yml issues or warehouse connection errors.
dbt Cloud CLI: dbt_cloud.yml not found / not authenticated
TL;DR: the CLI reads its credentials from dbtcloud.yml, which lives in your project dir and must contain a valid api key plus the right account, project, and environment ids. Regenerate it from the dbt Cloud UI (Develop > configure the IDE / download dbtcloud.yml), drop it in the project root, and rerun from that directory. If the file exists but auth still fails, the api key or ids are stale.
dbt_cloud.yml not found / not authenticatedSteps
- In the dbt Cloud UI, go to your profile settings and generate a fresh api key. Then download or copy the generated dbt_cloud.yml for your environment.
- Place dbt_cloud.yml in the root of the project you run the CLI from. The CLI looks in the current directory, not ~/.dbt.
- Run
dbt-cloud --versionor a lightweight command from that directory. Expected: it authenticates instead of complaining about the config file.
- Still failing: verify accountid, projectid, and environment_id in the file match the dbt Cloud URL you log into, and that the api key has not been revoked.
When this applies
- the dbt Cloud CLI (the
dbt-cloudbinary) reporting a missing or invalid dbt_cloud.yml not authenticatederrors before any dbt command runs against dbt Cloud- a fresh machine where the CLI was installed but never configured
When it doesn't
- dbt Core's profiles.yml — the Cloud CLI does not read it
- warehouse credential errors inside a run (the Cloud auth already succeeded)
- SSO browser flows for the dbt Cloud web UI itself
Compatibility
dbt Cloud CLI; dbt_cloud.yml format from the official dbt Cloud CLI configuration docs.
Variant phrasings
- dbt cloud cli dbt_cloud.yml not found
- dbt cloud cli not authenticated
- dbt-cloud configure authentication
Root cause
Unlike dbt Core, the Cloud CLI authenticates to the dbt Cloud API, not to your warehouse directly. dbt_cloud.yml is the whole credential bundle (host, ids, api key), so a missing file or a revoked key fails every command up front.
Edge cases
- running from a subdirectory means the CLI cannot find dbt_cloud.yml; cd to the project root first
- revoked api keys after a team member leaves produce the same
not authenticatedmessage - the generated file embeds your personal api key; do not commit it to git
Maintainer review
No maintainer verification is recorded for this version.
This records the version a maintainer checked. It does not assert that the version is the latest upstream release.