Why Shopify Stores Need a Smarter Chat
Shopify powers over 4.4 million stores worldwide, and they all share the same challenge: visitors have questions that product descriptions do not fully answer. What size should I order? Is this compatible with my existing setup? When will it arrive? What is your return policy?
Baymard Institute research shows that 69.8% of online shopping carts are abandoned. Among the top reasons are unexpected costs, complicated checkout, and unanswered questions about the product. You cannot fix all of those with an agent, but you can eliminate the last one entirely.
An AI shopping agent on your Shopify store answers product questions instantly, helps customers find what they need, and keeps them moving toward checkout instead of bouncing to a competitor.
Step 1: Create Your Agent on hiroi
- Sign in at hiroi.ai
- Click Create New Agent
- Configure the agent's personality to match your brand voice. If you sell premium skincare, the tone should be different from a skateboard shop.
- Upload your product FAQ, shipping policy, return policy, and sizing guides to the knowledge base
- Go to Settings and add your Shopify domains to the Allowed Domains list
For Shopify, you need to add:
your-store.myshopify.com(your Shopify admin domain)yourdomain.com(your custom domain, if you have one)www.yourdomain.com(the www variant)
Domain matching is exact, so add each variant separately.
Step 2: Add the Script to Your Shopify Theme
- From your Shopify admin, go to Online Store > Themes
- Click Actions > Edit Code on your active theme (or click the three dots and select "Edit code")
- In the left sidebar, find and click
theme.liquidunder Layout - Scroll to the bottom of the file and find the closing
</body>tag - Paste your embed code just before it:
<!-- hiroi AI Shopping Agent -->
<script src="https://hiroi.ai/widget.js"
data-site-id="your-site-uuid-here"></script>
</body>
- Click Save
That is it. The agent will appear on every page of your store within seconds.
Using Shopify Sections (Alternative)
If you prefer Shopify's section architecture, you can create a snippet instead:
- Under Snippets, click Add a new snippet
- Name it
hiroi-agent - Add the script tag as the snippet content
- In
theme.liquid, add{% render 'hiroi-agent' %}before</body>
This keeps your theme.liquid cleaner and makes it easy to toggle the agent on and off.
Step 3: Configure for E-commerce
With the agent live on your store, configure it to handle the questions your customers actually ask.
Product FAQ Handling
Upload or type your most common product questions into the agent's knowledge base:
- Sizing and fit: "Our shirts run true to size. For a relaxed fit, size up one."
- Materials and care: "Machine wash cold, hang dry. The fabric is 100% organic cotton."
- Compatibility: "This case fits iPhone 14 and 15 models. Not compatible with Pro Max."
- Shipping: "US orders ship within 2 business days. International orders take 7-14 days."
- Returns: "30-day returns on unworn items with tags attached. We provide a prepaid label."
The AI uses this information to answer questions naturally, not as robotic FAQ lookups but as conversational responses that reference specific products and details.
Size and Compatibility Questions
These are among the highest-intent questions a shopper asks. When someone asks "Will this fit a 32-inch waist?" they are ready to buy. They just need confirmation.
Configure your agent with your sizing charts, compatibility matrices, and product specifications. The agent can then answer these questions instantly, removing the friction that causes shoppers to leave and "think about it" (which usually means never coming back).
Order Status Inquiries
While the agent cannot directly access Shopify order data out of the box, you can configure it to:
- Direct customers to your order tracking page
- Explain your shipping timelines
- Provide your support email or phone number for specific order issues
- Answer general questions about shipping carriers and delivery expectations
For stores with a backend, session-signed authentication lets you pass customer context to the agent so it can provide personalized responses.
Reducing Cart Abandonment
The agent's biggest impact is often the quietest. It is not about flashy features. It is about answering the question that was going to make someone close the tab.
Consider the typical abandonment scenario:
- Customer finds a product they like
- They have a question about sizing, shipping, or compatibility
- They look for an FAQ page, do not find the answer quickly
- They leave "to come back later"
- They never come back
An AI agent short-circuits this at step 2. The answer is right there on the product page. No searching, no waiting for email support, no leaving the page.
Even a modest improvement in cart abandonment rates has a significant revenue impact. If your store does $50,000 per month and you reduce abandonment by just 5%, that is an additional $2,500 per month in revenue from conversations that cost you nearly nothing.
Page-Aware AI
One of the most powerful capabilities for Shopify stores is page integration. When configured, the AI agent is aware of what product the customer is currently viewing. Instead of asking "Which product are you looking at?", it already knows.
This means a customer on your running shoe product page can simply ask "Is this good for flat feet?" and the AI responds in the context of that specific shoe. No ambiguity, no back-and-forth.
To set this up, configure page fields in your hiroi dashboard that map to your Shopify theme's DOM elements. Common mappings include:
- Product title: The
h1or.product-titleelement - Product description: The
.product-descriptionor.product__descriptionelement - Price: The
.product-priceelement - Variant selector: For understanding which size or color is selected
Configuring Allowed Domains
Shopify stores often have multiple domains. Your Allowed Domains configuration should include every domain where customers might encounter your store:
- Your primary custom domain (
yourbrand.com) - The www variant (
www.yourbrand.com) - Your Shopify domain (
yourbrand.myshopify.com) - Any regional domains if applicable
The agent validates requests against this list using exact matching. If a customer accesses your store through a domain that is not on the list, the agent will not load. This is a security feature, not a limitation. It ensures your agent only runs on pages you control.
Measuring Impact
Once the agent is live, track these metrics from your hiroi dashboard:
- Conversation volume: How many customers are engaging
- Common questions: What your customers actually want to know (this is gold for improving your product pages)
- Peak hours: When most conversations happen (likely evenings and weekends, confirming the value of 24/7 availability)
Cross-reference this with your Shopify analytics. Watch for changes in conversion rate, average session duration, and cart abandonment rate. The data will tell you exactly how much the agent is contributing.
The stores that win in e-commerce are not always the ones with the lowest prices or the biggest ad budgets. They are the ones that answer the customer's question before the customer gives up asking.