Add Diwali lights to your Shopify store

Diwali is one of the biggest shopping weeks of the year in India. Make your Shopify store feel like the festival the moment shoppers land: glowing diyas, fireworks, a marigold toran or sky lanterns, without an app and without slowing your store down.

Free · one line of code · about 2 minutes
You'll need your free key first. It takes a minute and arrives by email.
Get my free code

Step by step

  1. Get your free widget code

    Register your store's domain at worldofaiagents.com/diwali (your custom domain, or yourstore.myshopify.com if you don't have one), verify your email and copy the script tag from the email.

  2. Open the code editor

    In Shopify admin go to Online Store → Themes. Next to your live theme click ⋯ (Actions) → Edit code.

  3. Open theme.liquid

    In the Layout folder, open theme.liquid.

  4. Paste before

    Find the closing </body> tag near the end of the file (Ctrl/Cmd + F helps), paste your code on the line just above it, and click Save.

  5. Check your store

    Open your store in a new tab. The lights appear on every page, including product, collection and cart pages.

Your code looks like this

<script async src="https://worldofaiagents.com/diwali/w.js" data-key="DL-YOURKEY" data-style="grand"></script>

Change data-style to diyas, fireworks, toran, lanterns or grand whenever you like. Optional: data-sparkler="off" removes the cursor sparkler, data-until="2026-11-20" switches the lights off after a date, and data-position="right" moves the small on/off button.

Tip: duplicate your theme first

If you'd like to preview before going live, use ⋯ → Duplicate on your theme, add the code to the copy, and use Preview. Publish the copy when you're happy, or just add the code to the live theme; it's a single line and easy to remove.

Turn the lights off after the sale

Add data-until="2026-11-20" to the script tag and the lights switch off by themselves after that date, so you don't need to edit the theme again after Diwali.

Troubleshooting

The lights don't show up
Make sure you saved theme.liquid on the live theme, not a draft copy. Check that the domain you registered is the one shoppers see. If you registered your custom domain, the key works on it and its subdomains.
Should I use Customer events (pixels)?
No. Shopify runs Customer events code in a sandbox that cannot draw on your storefront. Use theme.liquid as shown above.
My theme update removed it
Installing a new theme version replaces theme.liquid. Paste the line again into the new theme.

Questions

Is there a free Shopify app for Diwali animations?

You don't need an app. Diwali Lights is a free single line of code you paste into theme.liquid, so there are no app fees, no app permissions, and nothing left behind when you remove it.

Will it affect my store speed or conversions?

The script is about 12 KB compressed and loads after your store, so it doesn't delay your page. It never blocks clicks, so Add to cart and checkout buttons keep working as normal.

Does it work on Shopify checkout?

Shopify does not allow custom scripts on checkout pages, so the lights show on the storefront (home, collections, products and cart) but not inside checkout.

Light up your Shopify site today

The lights on this page are the real widget. Try every style on the main page.

Get my free Diwali lights 🪔

Other guides