> For the complete documentation index, see [llms.txt](https://docs.dinmo.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.dinmo.io/models/overview/model-materialization.md).

# Model materialization

When creating a model in DinMo, you can choose whether to **materialize** it in your data warehouse or keep it **non-materialized** (live).\
This setting impacts data freshness, performance, and query costs.

{% hint style="info" %}
Here is an overview of the difference between a materialized model and a live model, to help you choose based on your use cases.
{% endhint %}

### Model modes

#### Materialized Models

A **materialized model** stores query results as a physical table in your data warehouse (e.g., BigQuery, Snowflake).\
The table is **refreshed on a defined schedule**.

**How it works:**

* DinMo executes the model’s SQL and writes the results to a dedicated table.
* Subsequent operations (segment creation, activation, predictions) read directly from this table.

**Pros**

* Faster queries and improved performance.
* Reduced query costs (reused results).
* Stable data snapshot for consistent analysis.

**Cons**

* Data freshness depends on the refresh schedule.

#### Live Models

A **live (=non-materialized model)** remains a logical view — it is **queried in real time** each time it’s used.

**How it works:**

* DinMo runs the SQL query on-demand whenever the model is referenced.
* Results always reflect the **most up-to-date data** in your warehouse.

**Pros**

* Always fresh data.
* No need to manage refreshes.

**Cons**

* Slower query execution (SQL runs at each use).
* Higher warehouse costs for frequent access.

### Model configuration

By default, a model is always live. If you want to materialize it for cost or performance reasons, you can do so in the model's advanced settings.

#### At the model's creation

When choosing the table or entering the SQL query that determines the model definition, there is an “Advanced settings” option.

Click on this option and check the box to materialize the model as a table.

<figure><img src="/files/QyI9JdRNJSVkd6Dsna0Y" alt="" width="563"><figcaption></figcaption></figure>

You can then choose the refresh frequency for your model (based on intervals or a custom recurrence)

#### At the model's edition

It is possible to switch from a live model to a materialized model by going to the setup page for the model in question and clicking on “Edit.”

The flow then remains the same as [when creating a model](#at-the-models-creation).

### Materialization History

The "Materialization history" tab allows you to view the history, with the status of each run, the objects affected (entire model and/or computed fields), and the time of the update.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.dinmo.io/models/overview/model-materialization.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
