# How to Use Shopify Magic to Generate New Theme Blocks for Testing

Shopify’s AI-powered theme block generator is a fast and intuitive way to create new, customizable content blocks for your storefront — no coding required. Combined with Shoplift’s template testing capabilities, this becomes a powerful way to rapidly build and test new experiences before rolling them out broadly.

This guide walks you through how to use **Shopify Magic to generate new blocks**, and how to **quickly set them up in Shoplift for testing**.

{% stepper %}
{% step %}

### Set up a template test in Shoplift

1. **Log into Shoplift** and click **Create Test**.
2. On the **Test Draft** page, select **Test a template** and select the template you want to test from the drawer. This will be your Original (A).
3. Now create a variant. This will be the template that you generate a new theme block for. You can either **duplicate** your Original (A), or **select an existing template** from your theme to create your Variant (B).
4. Once you have a Variant (B) set in the draft, click **Edit in Shopify** to navigate to the theme editor and make changes to your variant template.
   {% endstep %}

{% step %}

### Generate a theme block with Sidekick

1. In the Shopify Theme Editor, confirm you are on your variant template by referencing the **template drop-down menu** in the top navigation.
2. Click the section you want to generate a new block for.
3. Click **Add Block.**
4. Click **Generate**.
5. Enter a prompt for the type of block that you want to generate. The more clear you are with your instructions, the better the result will be. For example: *"Create a product grid section with cards that display a drop shadow and slightly elevate when hovered over. Each card should contain the product image, title, price, and an add to cart button."*

{% hint style="info" %}
If you don't see the **Generate** button, click the **Sidekick** button in the Theme Editor (looks like a superhero, and is located next to the **Interact** and **Device View** buttons. When the Sidekick chat window opens, enter your prompt here.
{% endhint %}

6. **Submit** your prompt, and Shopify Magic will begin to generate your new theme block. You can follow along as it generates new liquid code for your theme in realtime.
7. When your new block is finished generating, add content and adjust the styling as you see fit. You can also continue to play with **Follow up instructions** to continue to tweak your new block.

<figure><img src="https://314821113-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FDg2m2UmvTCMjmBjnzBKA%2Fuploads%2FzMixu2MPH9LljknjOPdx%2FScreenshot%202025-06-05%20at%209.02.40%E2%80%AFAM.png?alt=media&#x26;token=bc9236b8-d2c0-4e08-af3d-9ec6599f8675" alt=""><figcaption></figcaption></figure>
{% endstep %}

{% step %}

### Launch your test!

1. Once your variant is ready for testing, return to Shoplift and configure the rest of your test settings, including device targeting, visitor targeting, and any custom audiences.
2. When everything looks good, click "Launch now". Or, if you want to schedule your launch for later, click the **Schedule test** button to set a schedule for an automated start and end time.
   {% endstep %}
   {% endstepper %}

## Why use Shopify Magic + Shoplift?

Using Shopify Magic to build new blocks allows for **rapid experimentation** without engineering involvement. With Shoplift, you can confidently test these new experiences and make data-backed decisions on what drives real impact.

This combo is perfect for:

* Testing promotional banners
* Creating custom product highlights
* Trying new layouts for upsells or bundles
* Adding content blocks for education or storytelling

## FAQ

**Can I edit the block code after using Shopify Magic?**

Yes. Generated blocks are added as editable Liquid sections. You can customize them like any other block.

**What if my theme doesn’t support Shopify Magic?**

Shopify Magic block generation is only available in **2.0 themes**. Consider upgrading your theme if you don’t see the options to generate blocks with Shopify Magic.

To learn more about how to generate new theme blocks with Shopify Magic, check out Shopify's guide [here](https://help.shopify.com/en/manual/online-store/themes/customizing-themes/theme-editor/shopify-magic/generate-blocks).


---

# 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.shoplift.ai/learn/guides/how-to-use-shopify-magic-to-generate-new-theme-blocks-for-testing.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.
