dbt: Could not find profile named 'jaffle_shop'
Fixes dbt failing with Could not find profile named 'jaffle_shop'. Use when dbt run, dbt test, or any dbt command exits because the profile name in dbt_project.yml has no matching entry in profiles.yml. Confirms the profile name match, checks the profiles dir, and fixes the mismatch. Not for warehouse connection failures after the profile is found.
dbt: Could not find profile named 'jaffle_shop'
TL;DR: the name in dbtproject.yml has no matching profile block in profiles.yml, or dbt is reading a different profiles.yml than you think. Open ~/.dbt/profiles.yml, add (or rename) the block so its name matches the profile: value in dbtproject.yml exactly, or point dbt at the right file with --profiles-dir.
Could not find profile named 'jaffle_shop'Steps
- Check the profile name your project expects: open dbt_project.yml and read the
profile:line.
- Open the profiles file dbt is actually reading, usually ~/.dbt/profiles.yml, and look for a top-level block with that exact name. Expected: the block exists and the spelling, underscores, and case match exactly.
- If dbt uses a custom profiles dir, either set DBTPROFILESDIR to that directory or pass --profiles-dir [path]. Verify with
dbt debug --profiles-dir [path], which prints the path it read.
- Rename the block or the
profile:value so they agree, save, and rerundbt debug. Expected:dbt debugreports the connection instead of the not-found error.
When this applies
- the exact
Could not find profile namederror on dbt run, dbt test, or dbt debug - a project that worked on another machine but not this one (different ~/.dbt/profiles.yml)
- CI runs where the profiles file is generated at build time
When it doesn't
- warehouse auth failures like wrong password or host unreachable — the profile was found, the connection is the problem
- dbt Cloud CLI errors about dbt_cloud.yml, which uses a different auth file
- Jinja/env_var errors inside a profile that already resolves
Compatibility
dbt Core and dbt Fusion CLIs; profiles.yml in ~/.dbt (or DBTPROFILESDIR / --profiles-dir). Verified against the dbt troubleshooting FAQ.
Variant phrasings
- dbt could not find profile named
- dbt profile not found error
- dbt debug profile named error
Root cause
dbt resolves the project name to a profile name via dbt_project.yml, then looks that name up in profiles.yml. Any typo, renamed project, or wrong profiles dir breaks the lookup before any connection attempt.
Edge cases
- DBTPROFILESDIR pointing at an empty dir in CI gives this error with zero hint about the path; print it in the failing step
- profiles.yml with a
.bakextension or YAML syntax error can also surface as not-found rather than parse-failed - dbt Cloud CLI ignores profiles.yml entirely; this skill is Core-only
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.