User settings
~/.dbt/user_settings.yml is a user-scoped configuration file for personal dbt preferences. Because it always lives at ~/.dbt/, it applies globally across all projects on your machine, regardless of which project you're running or where your profiles.yml is located.
Today, user_settings.yml is primarily written by dbt login to configure dbt State locally (manage_state). dbt may add other user-scoped flags to this file over time.
Settings in this file are separate from project-level configuration (dbt_project.yml) and connection configuration (profiles.yml). Use this file for preferences that belong to you, not the project, as an alternative to setting environment variables or populating an .env file.
flags:
manage_state: true
Some dbt commands write to this file automatically. You can also edit it manually.
When you run dbt login, both authentication paths write to user_settings.yml:
- Log in with your dbt platform account
- In the dbt Fusion engine, the CLI prompts you before writing to
user_settings.yml. - In dbt Core v1.12, dbt writes
manage_state: trueautomatically without prompting — because it's the only thingdbt logindoes in v1.12, and ensures your configuration travels with you when you upgrade in the future. - Setting
manage_state: trueenables dbt State locally on everydbt runordbt build.
- In the dbt Fusion engine, the CLI prompts you before writing to
- Log in with the standalone dbt State app: After you create an account, dbt automatically enables dbt State locally in
user_settings.yml.
If user_settings.yml already contains a value, dbt login prompts you before overwriting it.
Config precedence
user_settings.yml is the lowest precedence level in dbt's flag hierarchy. More specific settings always override it. For more on flag precedence, refer to About flags (global configs).
- CLI option (highest)
- Environment variable
- Project scope (
dbt_project.yml) - User scope (
~/.dbt/user_settings.yml) (lowest)
For example, if manage_state: true is set in user_settings.yml but you run dbt run --no-manage-state, the CLI flag takes precedence, and dbt disables dbt State for that invocation.
When dbt State is enabled locally but not in dbt platform
If manage_state: true is set in user_settings.yml but dbt State is not enabled in your dbt platform account, dbt fails with an error on your next dbt run or dbt build. To resolve this, either:
- Enable dbt State in your dbt platform account.
- Disable dbt State locally by setting
manage_state: falseinuser_settings.yml, or rundbt run --no-manage-state.
Was this page helpful?
This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.