WordPress Conversion Tracking
Step 1: Add the Rumble Global Site Tag to your WordPress website
To track events and conversions, you need to add the Rumble Global Site Tag to the head section of your WordPress site. This will allow you to send events and conversions to Rumble Ads.
- Log in to your WordPress dashboard.
- Navigate to Appearance > Theme Editor.
- Select your theme's
header.php
file (located in the right sidebar under Theme Files). - Paste the following Rumble Global Site Tag code within the
<head>
tag of your WordPress site:
<script async src="https://a.ads.rmbl.ws/ratag?id=AV-XXXX"></script>
<script>
window._ratagData = window._ratagData || [];
function ratag() {_ratagData.push(arguments);}
</script>
- Select Update File to save the changes.
These steps will ensure that the Rumble Global Site Tag is loaded on every page of your WordPress site.
Step 2: Trigger conversion actions
After adding the Global Site Tag, you need to trigger conversion events on your WordPress site. There are two common methods to trigger conversion events:
- Page Load: Use this method if the conversion event occurs when a specific page loads (e.g., a "Thank You" page after a form submission or purchase).
- Button Click: Use this method if you want to track conversions based on specific user actions (e.g., clicking a button or completing a form).
Conversion tracking on page load
To track a conversion when a user reaches a specific page (such as a "Thank You" page):
- Navigate to the WordPress page where you want to track conversions (e.g., the order confirmation page).
- Add the following Rumble Conversion Script to that page using a custom HTML block in the WordPress editor, or by editing the page's source code:
<script>
ratag('conversion', {to: XXXX}); // Replace XXXX with your specific conversion action ID from Rumble
</script>
- Publish or update the page to save the changes.
Now, whenever this page loads, the conversion will be triggered and sent to Rumble.
Conversion tracking on button click
To track conversions when a user clicks a button:
- Identify the button or form you want to track for conversions on your WordPress site.
- Add the following Rumble Conversion Script to the button's
onclick
attribute:
<button onclick="ratag('conversion', {to: XXXX});">Click Here</button>
- Replace
XXXX
with your specific Conversion Action ID from Rumble Ads.
- You can add this code directly into your page's HTML, or by using a custom HTML block in the WordPress editor.
- Save and test the button to ensure that the click triggers the conversion event.
Step 3: Test your implementation
Complete a test conversion by visiting the page where the tracking code is placed (for page load) or by clicking the tracked button (for click tracking). Check your Rumble Ads account to ensure that the conversion has been recorded correctly.
Important notes
- Conversion Action ID: Ensure that you replace the
XXXX
in the conversion script with your specific Conversion Action ID, which can be found in your Rumble Ads account under the "Conversion Actions" section. - Testing: Always test both page load and click events to confirm that the conversion data is being sent to Rumble Ads correctly.
By following these steps, you’ll have Rumble Ads conversion tracking integrated into your WordPress site using both page load and click event triggers, ensuring accurate tracking of your conversions.