is_incremental() is a Jinja helper that returns true when dbt is running an incremental model in incremental mode (the target table already exists and you are not doing a full refresh).
Typical use
Wrap filters so the first build loads history, and later builds only load new data:
select * from {{ ref('stg_events') }}
{% if is_incremental() %}
where event_time > (select max(event_time) from {{ this }})
{% endif %}When it is false
- First run (relation does not exist yet)
dbt run --full-refresh- Non-incremental materializations (the block simply should not appear, or still evaluates false)
Mental model
is_incremental() == false → process full SELECT (history) is_incremental() == true → process filtered SELECT (delta)
Common mistake
Putting the filter outside of is_incremental() so the first run also filters against an empty/missing {{ this }} and loads nothing.
Interview tip: "is_incremental() switches between backfill SQL and delta SQL inside one model file."