Skip to main content

Source configurations

Available configurations

Source-specific configurations

  • None

General configurations

Configuring sources

Sources can be configured from the dbt_project.yml file under the sources: key. This configuration is most useful for configuring sources imported from a package. You can disable sources imported from a package to prevent them from rendering in the documentation, or to prevent source freshness checks from running on source tables imported from packages.

Unlike other resource types, sources do not yet support a config property. It is not possible to (re)define source configs hierarchically across multiple yaml files.


Disable all sources imported from a package

To apply a configuration to all sources included from a package, state your configuration under the project name in the sources: config as a part of the resource path.


sources:  events:    +enabled: false

Disable a specific source

To disable a specific source, qualify the resource path for your configuration with both a package name and a source name.


sources:  events:    clickstream:      +enabled: false

Similarly, you can disable a specific table from a source by qualifying the resource path with a package name, source name, and table name:

sources:  events:    clickstream:      pageviews:        +enabled: false

Example source configuration

The following is a valid source configuration for a project with:

  • name: jaffle_shop
  • A package called events containing multiple source tables
name: jaffle_shopconfig-version: 2...sources:  # project names  jaffle_shop:    +enabled: true
  events:    # source names    clickstream:      # table names      pageviews:        +enabled: false      link_clicks:        +enabled: true