# Static Blocks

Static Theme Blocks give theme developers greater control over how blocks and sections are structured. Unlike regular Theme Blocks, they are rendered statically in Liquid rather than dynamically.&#x20;

Because of this, Static Theme Blocks are especially useful when:&#x20;

* A theme requires blocks that should not be moved or removed by the merchant
* Blocks can be rendered conditionally,&#x20;
* having multiple places where you want to add nested blocks to a section

Static Theme Blocks still allow full access to customizable settings, ensuring flexibility without sacrificing control.

<a href="https://shopify.dev/docs/storefronts/themes/architecture/blocks/theme-blocks/static-blocks" class="button secondary">Shopify Docs</a>

Static Theme Blocks can be created by adding the li-static-block attribute to a \<div>:

{% columns %}
{% column %}
{% code title="Webflow" fullWidth="false" %}

```
li-static-block = Item
```

{% endcode %}
{% endcolumn %}

{% column %}
{% code title="Shopify" fullWidth="false" %}

```html
{% content_for "Item", type: "type", id: "uniqueid" %}
```

{% endcode %}
{% endcolumn %}
{% endcolumns %}

This generates a new block file, which is then referenced directly within the corresponding Liquid file.

<figure><img src="/files/rLfaLEg2QEoAW7XeZnHD" alt=""><figcaption></figcaption></figure>

{% tabs %}
{% tab title="li-static-block="Item"" %}
and this: Inside this element, you can then use all the elements as usually. For example li-cf-theme-blocks to nest other blocks inside.
{% endtab %}
{% endtabs %}

#### Loop or conditionally render static blocks.

To loop over or conditionally render a static block, simply wrap it in a `div` and add either `li-for:inside` or `li-if:inside`. This will also be reflected in the Shopify Theme Editor. Learn more about [looping](/liquid-attributes/iteration-lists.md) and [conditional rendering here.](/liquid-attributes/conditional.md)

<figure><img src="/files/dqq5Pd8wfieIE3qc25E7" alt=""><figcaption></figcaption></figure>

#### Adding Parameters to your Static Blocks

If you want to pass data into your static blocks, you can use the attribute modifier like this:

{% code title="Webflow" fullWidth="false" %}

```
li-static-block = Item
li-static-block::attributes=current.product: product
```

{% endcode %}

This allows you to access dynamic data from the for loop like this:&#x20;

<figure><img src="/files/ax7vURpQkUmjaaHsXzhz" alt=""><figcaption></figcaption></figure>


---

# Agent Instructions: 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:

```
GET https://docs.liquiflow.app/section-settings/static-blocks.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
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.
