Add a Voice AI Agent to ExpressionEngine
Add the AnveVoice voice agent to ExpressionEngine by editing a footer embed or layout template in Developer > Templates, with caching and file-sync notes.
How to add AnveVoice to an ExpressionEngine site
In ExpressionEngine you add the AnveVoice tag to the template that closes every page, normally a hidden footer embed or a shared layout template, using the Template Manager under Developer > Templates. Save it, clear any template caching, and every template that uses that footer carries the voice agent. Steps checked against the official documentation on 2026-10-14.
At a glance
- Where the code goes: Your footer embed or layout template, edited in Developer > Templates
- Coding needed: Paste one line into a template; no PHP, no add-on
- Plan limits: The docs describe no feature tier for template editing, but you need Control Panel access to templates
- Version note: Menu names follow ExpressionEngine 6 and 7 docs; older releases use Design > Templates
How ExpressionEngine assembles a page
Templates in ExpressionEngine belong to template groups, which behave like folders, and the documentation describes two ways of sharing markup between them. Embeds insert one template into another with the embed tag, and names that start with an underscore make a template hidden, so it can be embedded but not loaded directly by URL. Layouts work the other way round: a layout is a wrapping template, selected at the top of a template with the layout tag, and it prints the child template wherever layout:contents appears. Whichever your site uses, one template contains the closing body tag. That is where the AnveVoice line belongs, because editing it once covers every template that includes it. Find your embed ID first at app.anvevoice.app after creating a free voice bot.
- 1. Keep the tag ready — Replace YOUR_EMBED_ID with your own value. You may add &position=bottom-left or &theme=dark to the address. Code: <script src="https://anvevoice.app/embed.js?embedId=YOUR_EMBED_ID" async></script>
Method 1: edit the shared template in the Control Panel
- 1. Open the Template Manager — In the Control Panel choose Developer, then Templates. The manager lists template groups; click a group name to see its templates.
- 2. Open the footer or layout — Open the hidden template that closes your pages, for instance something like _footer or _html-layout. If you are unsure, open a page template and look for an embed or layout tag at its top or bottom.
- 3. Paste above the closing body tag — On the Edit tab, add the AnveVoice line immediately before </body>. The tag contains no curly braces, so ExpressionEngine's parser leaves it alone.
- 4. Save — Save the template and load a front-end page. The docs also offer a View Rendered Template tab if you want to preview inside the Control Panel.
Method 2: edit template files on disk
By default ExpressionEngine stores templates in the database and also saves them as files, controlled by the save_tmpl_files setting in system/user/config/config.php. Files live under system/user/templates/ in a folder named for your site, with one folder per group ending in .group; webpage templates use the .html extension, and hidden templates begin with an underscore. If your team edits files in version control, change the footer template's .html file there. The docs state that synchronisation happens when any site page is accessed, and new files show up once you visit Developer > Templates or load the template on the front end. Note that the docs list the matching option for saving global variables separately, and it only works when file saving is on.
Template caching and access settings
Each template has a Settings tab where caching can be enabled with a refresh interval. If your footer template or the templates embedding it are cached, the new line will not appear until the cache refreshes, so clear the cache or temporarily switch caching off while you test. The Access tab limits which member roles can view a template. A footer template that only certain roles may see would hide the tag from other visitors. Hidden underscore templates avoid that confusion because they are embedded rather than visited.
Check that it works
- 1. Reload as a visitor — Open a front-end page in a private window. Pages built from templates that do not include your footer will not show the button, so test one of each template type.
- 2. Try the button — Click the round microphone at bottom-right, allow microphone access, and ask a question that your pages answer.
- 3. Count the scripts — Search the page source for anvevoice.app. One result is what you want.
Common problems
- Edit saved but nothing changes: template caching is on, or a CDN or reverse proxy holds the old HTML.
- Only some pages show the agent: those templates do not embed or use the layout you edited, so add the footer embed there.
- File edits ignored: the files are in a different site folder, or save_tmpl_files is off so the database copy is the source of truth.
- Microphone does not prompt: the site must run on HTTPS.
Sources
- ExpressionEngine docs: Template Manager (Developer > Templates) (https://docs.expressionengine.com/latest/control-panel/template-manager.html) — checked 2026-10-14
- ExpressionEngine docs: Templates overview (embeds, hidden templates, file-based templates) (https://docs.expressionengine.com/latest/templates/overview.html) — checked 2026-10-14
- ExpressionEngine docs: Template layouts (https://docs.expressionengine.com/latest/templates/layouts.html) — checked 2026-10-14
Related
- How to add AnveVoice to a ProcessWire site
- How to add AnveVoice to a Grav site
- How to add AnveVoice to a DNN site
- How to add AnveVoice to a plain HTML website
Try AnveVoice on your site
Free plan: $0, 50,000 tokens a month, no card. Get your embed ID in the dashboard, then paste one tag.