Integrate Vemetric into your WordPress website

Easily integrate Vemetric into your WordPress website.


WordPress is a popular CMS for building websites.

We published a WordPress plugin that allows you to easily integrate Vemetric into your WordPress website. Follow the steps below to get started.

Installation

Install the plugin

You can install the Vemetric Plugin via your Admin Dashboard in WordPress. Navigate to Plugins > Add Plugin and search for Vemetric.

Screenshot of the WordPress Plugin installation

Configure your Token

Once you’ve installed the plugin, you can configure your project token in the plugin settings. Navigate to Settings > Vemetric and enter your project token (found in the settings of your Vemetric project).

Screenshot of the WordPress Plugin settings

You can also configure all the other settings you see on the Screenshot. Refer to the HTML Script Docs for more details about the available options.

Verify installation

Once you’ve added your token and saved the settings, Vemetric will automatically start tracking page views on your site (each page load will be recorded). You can verify this by checking your Vemetric dashboard for incoming pageview events a few seconds after loading a page.

Data from localhost won’t be tracked.

Keep in mind that one project can be used to track data from multiple websites, which can be useful when you for example want to track users across your landing page and web application. We’ve also created a guide on how to track data across subdomains.

Vemetric’s snippet will initialize a global function window.vmtrc for tracking events and other functionality. See the Tracking Custom Events or User Identification sections for more details.

Further integrations

The Wordpress plugin adds the HTML script to your website automatically. Checkout the HTML Script Docs to see how to send custom events or identify users.

It also initiates the PHP SDK for tracking events in your PHP code. It exposes a global function vemetric which returns a new instance of the Vemetric Client. Here’s an example:

<?php
$vm = vemetric();
$vm->trackEvent('SignupCompleted', [
    'userIdentifier' => 'your-user-identifier',
    'eventData'      => ['plan' => 'Pro'],
    'userData'       => ['setOnce' => ['signupSource' => 'landing-page']],
]);

Easily integrate Vemetric using Google Tag Manager.

Easily integrate Vemetric into your Next.js application.

Ready to understand your users?

Start tracking
Pricing About Documentation Changelog Blog
0 stars