Enable Cookie Banner in AI Builder Manual Mode
In this article
This guide shows you how to turn on the cookie banner in AI Builder and set it to manual mode, giving you full control over when and how the banner appears to visitors. Manual mode means the banner won't auto-show; instead, you trigger it via a button, link, or custom event. This is useful for sites that need to comply with consent regulations while keeping the banner from interrupting the first visit. You'll need access to the AI Builder project where your cookie banner is configured.
What You'll Need
- An AI Builder account with an existing cookie banner project (or the ability to create one).
- Editor or admin permissions on that project.
- A basic understanding of where your site's footer or header code lives (to add the trigger button).
Step-by-Step
- Log in to AI Builder and open the project that contains your cookie banner. If you don't have one yet, create a new banner from the dashboard.
- Go to the 'Display Settings' tab in the banner editor. This is usually found in the left sidebar or top menu, depending on your version.
- Locate the 'Trigger Mode' or 'Display Mode' dropdown. It typically has options like 'Auto', 'Manual', or 'On Scroll'.
- Select 'Manual' from the dropdown. This tells AI Builder not to show the banner automatically on page load.
- Save your changes by clicking the 'Save' or 'Publish' button. The banner is now in manual mode, but it won't appear until you trigger it.
- Find your unique banner ID. After saving, look for a 'Banner ID' or 'Embed Code' section in the settings. You'll need this to write the trigger code.
- Copy the trigger script that AI Builder provides (if available). Some versions give you a ready-made snippet like
AiBuilder.showBanner('YOUR_BANNER_ID'). - Add a trigger element to your site. For example, add a button in your footer with an onclick attribute:
<button>Cookie Settings</button>. Replace 'YOUR_BANNER_ID' with the actual ID. - Test the trigger. Open your site in a private or incognito window (to avoid cached cookies) and click the button. The banner should appear.
- Publish your changes if you're using a staging environment, then deploy to production.
Common Mistakes
- Forgetting to save after switching to manual – the old auto settings might still be active.
- Using the wrong banner ID – copy it directly from the dashboard, don't type it manually.
- Not clearing cookies when testing – if you've already accepted the banner, it won't show again, so test in incognito mode.
- Placing the trigger code in the wrong file – ensure the script is in the footer of every page where you want the banner to appear.
- Assuming manual mode means the banner never shows – it only shows when you call the trigger function, which is exactly what you want.
Tips
- Use a recognizable label for your trigger button, like 'Cookie Preferences' or 'Manage Cookies', so users know what it does.
- Test on multiple devices to ensure the trigger works on mobile and desktop layouts.
- Keep the trigger script in a central place (like a theme file) so you don't have to edit every page.
- If you have multiple banners, make sure each has a unique ID and you're calling the right one.
- Consider adding a fallback – if JavaScript fails, the banner won't show, so you might want a noscript fallback or a link to a cookie policy page.
Troubleshooting
Banner still shows automatically after switching to manual. Clear your browser cache and cookies, then reload. If it persists, double-check that you saved the settings and that you're viewing the correct project version.
Trigger button does nothing. Open your browser's developer console (F12) and look for JavaScript errors. Make sure the AI Builder script is loaded before your trigger code. Also verify that the banner ID is correct and that the function name matches what AI Builder uses (it might be showBanner or openBanner).
Banner appears but then disappears immediately. This can happen if the banner is set to auto-hide after a few seconds. Check the 'Auto-hide' or 'Duration' settings in the banner editor and disable it if you want the banner to stay until the user closes it.
Manual mode works on one page but not another. Ensure the trigger script is included on every page where you want the banner to be available. If you're using a CMS, add it to the global footer.
After clicking accept, the banner won't show again even after clearing cookies. Some browsers or privacy settings may block third-party scripts. Test in a different browser or with a clean profile.
Frequently Asked Questions
What does manual mode actually do?
It disables the automatic display of the cookie banner on page load. The banner only appears when you explicitly call the show function, typically via a button click.
Can I still use manual mode if I have multiple banners?
Yes, each banner has its own ID, and you can trigger them individually. Just make sure to call the correct function for each.
Will manual mode affect my site's compliance with cookie laws?
It can, if users never see the banner. You should provide a visible trigger (like a footer link) so users can access cookie settings at any time. Many regulations require that consent be freely given and easily withdrawn.
Do I need to write custom code to use manual mode?
Yes, you'll need to add a small JavaScript snippet to your site. AI Builder provides the function, but you must call it from your own button or link.
Can I set manual mode for a specific page only?
Yes, simply include the trigger code only on the pages where you want the banner to appear. Other pages won't have the trigger, so the banner won't show there.
How do I know if my banner is in manual mode?
In the AI Builder dashboard, the Display Settings should show 'Manual' as the selected trigger mode. Also, the banner won't auto-show on your site until you trigger it.