MediaMath Event Tracking | Blue Frog Docs

MediaMath Event Tracking

Complete guide to MediaMath conversion tracking and attribution

MediaMath Event Tracking

Overview

MediaMath (now part of Infillion) uses conversion pixels for tracking user actions and campaign performance across its demand-side platform. As an enterprise programmatic advertising platform, MediaMath provides sophisticated tracking for display, video, mobile, and connected TV campaigns with advanced attribution and audience segmentation.

Standard Events

MediaMath supports conversion tracking through pixels:

Conversion Types

  • Purchase - Transaction completed
  • Lead - Form submission or contact
  • Page View - Specific page visited
  • Custom - Business-specific actions

Custom Events

Creating Conversion Pixels

Define conversion tracking via pixel implementation:

<!-- Standard Conversion Pixel -->
<img src="https://pixel.mathtag.com/event/img?mt_id=ADVERTISER_ID&mt_adid=AD_ID&mt_exid=CONVERSION_ID&mt_excr=ORDER_VALUE&v1=&v2=&v3=" width="1" height="1" />

Dynamic Parameters

Pass dynamic values:

<!-- Dynamic Conversion Pixel -->
<script type="text/javascript">
var mt_id = "ADVERTISER_ID";
var mt_adid = "AD_ID";
var mt_exid = "CONVERSION_ID";
var mt_excr = "99.99";  // Order value
var v1 = "ORDER_12345";  // Order ID
var v2 = "SKU_123";      // Product ID
var v3 = "electronics";   // Category
</script>
<script type="text/javascript" src="https://pixel.mathtag.com/event/js?mt_id=' + mt_id + '&mt_adid=' + mt_adid + '&mt_exid=' + mt_exid + '&mt_excr=' + mt_excr + '&v1=' + v1 + '&v2=' + v2 + '&v3=' + v3"></script>

Ecommerce Events

Purchase Tracking

<!-- Purchase Pixel -->
<img src="https://pixel.mathtag.com/event/img?mt_id=YOUR_ADVERTISER_ID&mt_adid=YOUR_AD_ID&mt_exid=PURCHASE_PIXEL_ID&mt_excr=149.99&v1=ORDER_12345&v2=SKU_123&v3=2" width="1" height="1" />

Parameters:

  • mt_id - MediaMath Advertiser ID
  • mt_adid - Ad ID
  • mt_exid - Conversion Pixel ID
  • mt_excr - Order value
  • v1 - Custom variable 1 (e.g., Order ID)
  • v2 - Custom variable 2 (e.g., Product ID)
  • v3 - Custom variable 3 (e.g., Quantity)

Conversion Tracking

Implementation Methods

1. Image Pixel

Standard image pixel:

<img src="https://pixel.mathtag.com/event/img?mt_id=ADVERTISER_ID&mt_adid=AD_ID&mt_exid=CONVERSION_ID&mt_excr=99.99&v1=ORDER_12345" width="1" height="1" />

2. JavaScript Pixel

JavaScript implementation for dynamic values:

<script type="text/javascript">
var mt_id = "ADVERTISER_ID";
var mt_adid = "AD_ID";
var mt_exid = "CONVERSION_ID";
var mt_excr = document.getElementById('order-total').textContent;
var v1 = document.getElementById('order-id').textContent;
</script>
<script type="text/javascript" src="https://pixel.mathtag.com/event/js?mt_id=' + mt_id + '&mt_adid=' + mt_adid + '&mt_exid=' + mt_exid + '&mt_excr=' + mt_excr + '&v1=' + v1"></script>

3. Server-Side

Server-to-server tracking:

import requests

# Server-side conversion
pixel_url = "https://pixel.mathtag.com/event/img"
params = {
    "mt_id": "ADVERTISER_ID",
    "mt_adid": "AD_ID",
    "mt_exid": "CONVERSION_ID",
    "mt_excr": "99.99",
    "v1": "ORDER_12345"
}

response = requests.get(pixel_url, params=params)

Attribution

Attribution Windows

Default Windows:

  • Post-click: 30 days
  • Post-view: 1 day

Configure in MediaMath platform per campaign.

Attribution Models

MediaMath supports:

  • Last-touch attribution
  • Multi-touch attribution (via Brain)
  • Custom attribution models

Debugging & Validation

Network Tab

Verify pixel fires:

  1. Open browser DevTools
  2. Navigate to Network tab
  3. Filter for "mathtag.com"
  4. Verify pixel request fires
  5. Check parameters are correct

Platform Validation

Verify in MediaMath platform:

  1. Navigate to Reports > Conversions
  2. Review conversion activity
  3. Check for pixel firing confirmation

Best Practices

Implementation

  1. Use JavaScript pixels for dynamic values
  2. Pass order value for revenue tracking
  3. Include order ID in v1 for deduplication
  4. Test pixels before launch
  5. Monitor conversion reports regularly

Optimization

  1. Use Brain optimization for automated bidding
  2. Create audience segments from converters
  3. Test different attribution models
  4. Leverage cross-device tracking
  5. Measure incrementality with control groups

Programmatic Strategy

  1. Use private marketplace deals for quality
  2. Implement brand safety controls
  3. Leverage first-party data for targeting
  4. Test different channels (display, video, CTV)
  5. Monitor viewability and fraud metrics
// SYS.FOOTER