Skip to content

Install Looma on WordPress / WooCommerce ​

This guide covers installing Looma on WordPress sites, including WooCommerce stores.

Prerequisites ​

  • A WordPress site with admin access
  • Your Looma installation code (available in Dashboard → Site Settings → Installation)

The easiest and safest way — no theme file editing required.

Step 1: Install WPCode Plugin ​

  1. Log in to your WordPress Admin panel
  2. Go to Plugins → Add New
  3. Search for "WPCode — Insert Headers and Footers"
  4. Click Install Now, then Activate

Step 2: Add the Script ​

  1. Go to Code Snippets → Header & Footer (in the left sidebar)
  2. In the Header section, paste your Looma installation code:
html
<script>
(function(d) {
    var s = d.createElement('script');
    s.defer = true;
    s.src = 'https://widget.looma.chat/loader.js?token=YOUR_SITE_TOKEN';
    if (d.head) d.head.appendChild(s);
})(document);
</script>
  1. Click Save Changes

Step 3: Verify ​

  1. Visit your website
  2. The Looma chat bubble should appear in the bottom-right corner
  3. Check the Looma Dashboard for the installation status

Method 2: Theme File Editor ​

If you prefer not to install additional plugins:

Step 1: Open Theme Editor ​

  1. Go to Appearance → Theme File Editor
  2. On the right side, find and click Theme Header (header.php)

Step 2: Add the Script ​

  1. Find the closing </head> tag
  2. Paste the Looma installation code right before it
  3. Click Update File

WARNING

Theme updates may overwrite your changes. If you use this method, consider creating a child theme first. The plugin method (Method 1) is safer and persists across theme updates.

Method 3: functions.php ​

For developers who prefer programmatic approach:

  1. Go to Appearance → Theme File Editor
  2. Open functions.php
  3. Add the following code at the end:
php
function looma_add_widget_script() {
    echo '<script>
    (function(d) {
        var s = d.createElement("script");
        s.defer = true;
        s.src = "https://widget.looma.chat/loader.js?token=YOUR_SITE_TOKEN";
        if (d.head) d.head.appendChild(s);
    })(document);
    </script>';
}
add_action('wp_head', 'looma_add_widget_script');
  1. Click Update File

Google Merchant Feed for WooCommerce ​

WooCommerce doesn't generate a Google Merchant feed by default. You'll need a plugin:

  1. Go to Plugins → Add New
  2. Search for "Product Feed PRO for WooCommerce"
  3. Install and activate
  4. Go to Marketing → Product Feed PRO
  5. Create a new feed → select Google Shopping template
  6. Configure and generate the feed
  7. Copy the feed URL and paste it in Looma Dashboard → Site Settings → Feed URL

Option 2: Google Listings & Ads ​

  1. Install the Google Listings & Ads plugin (official by Google & WooCommerce)
  2. Connect your Google Merchant Center account
  3. Products will sync automatically
  • CTX Feed — WooCommerce Product Feed Manager
  • JEXY — Google Shopping Feed
  • Flavflavor — Product Feed for WooCommerce

Troubleshooting ​

Widget doesn't appear ​

  • Check if a caching plugin is active (WP Super Cache, W3 Total Cache, LiteSpeed Cache). Clear the cache after adding the script
  • Try in incognito/private browsing mode
  • Check browser console for errors (F12 → Console tab)
  • Verify the site token is correct

Conflicts with other plugins ​

  • Some security plugins (Wordfence, Sucuri) may block external scripts. Add widget.looma.chat to the whitelist
  • If using a page builder (Elementor, Divi), make sure the script is in the global header, not in a page section

WooCommerce-specific issues ​

  • If the widget appears on some pages but not others, make sure the script is in the global header.php and not in a specific template
  • Check if your theme has separate headers for shop/product pages

Next Steps ​

Looma.chat — AI-powered e-commerce search & chat