Skip to content
Go to file

Latest commit


Git stats


Failed to load latest commit information.
Latest commit message
Commit time

Mautic - Grav Plugin

This is Grav CMS plugin that helps you configure Mautic tracking and converts markdown "links" into Mautic Form Embed code.


Installing the Mautic - Grav plugin can be done in one of two ways.

GPM Installation (Preferred)

The simplest way to install this plugin is via the Grav Package Manager (GPM) through your system's Terminal (also called the command line). From the root of your Grav install type:

bin/gpm install mautic

This will install the Mautic - Grav plugin into your /user/plugins directory within Grav. Its files can be found under /your/site/grav/user/plugins/mautic.

Manual Installation

To install this plugin, just download the zip version of this repository and unzip it under /your/site/grav/user/plugins. Then, rename the folder to mautic.

You should now have all the plugin files under


Config Defaults

enabled: true
url: true

If you need to change any value, then the best process is to copy the mautic.yaml file into your users/config/plugins/ folder (create it if it doesn't exist), and then modify there. This will override the default settings.


Mautic tracking

Tracking JS works right after you enable the plugin, insert the Base URL and save the plugin. That means it will insert JS into the head of your site from your Mautic instance. You can check HTML source code (CTRL + U) of your Grav website to make sure the plugin works. You should be able to find something like this:


    mt('send', 'pageview');

There will be probably longer URL query string at the end of the tracking image URL. It is encoded additional data about the page (title, url, referrer).

Mautic Form Embed

To use this plugin you simply need to include a Mautic Form ID in markdown link such as:


Example: [plugin:mautic](8) will load Mautic form with ID = 8.

This code snippet will be converted into the following:

<script type="text/javascript" src=""></script>

Mautic Dynamic Content Embed

To use this, simply include the Mautic dynamic content shortcode in your content.

[mautic type="content" slot="slot_name"]Default content to show when an unknown contact views this slot.[/mautic]

This code snippet will be converted into the following:

<div class="mautic-slot" data-slot-name="slot_name">Default content to show when an unknown contact views this slot.</div>


Mautic integration into Grav CMS





No packages published


You can’t perform that action at this time.