Idlen Logo
Features

Conversion Tracking

Track conversions and measure campaign performance

Conversion Tracking

Track conversions to measure the effectiveness of your ad campaigns.

Basic Conversion

idlen('track', 'Conversion');

Named Conversion

Add a name to categorize your conversions:

idlen('track', 'Conversion', {
  eventName: 'signup'
});

Conversion with Value

Track revenue or monetary value:

idlen('track', 'Conversion', {
  eventName: 'purchase',
  value: 99.99
});

Common Event Names

Event NameUse Case
signupUser registration
trial_startFree trial activation
purchaseCompleted purchase
leadForm submission
downloadApp or file download
subscribeNewsletter signup

Implementation Examples

Signup Form

const form = document.getElementById('signup-form');

form.addEventListener('submit', async (e) => {
  e.preventDefault();
  
  const result = await submitSignup(formData);
  
  if (result.success) {
    idlen('track', 'Conversion', { eventName: 'signup' });
    // Redirect to dashboard
  }
});

E-commerce Purchase

async function completePurchase(cart) {
  const order = await processPayment(cart);
  
  if (order.success) {
    idlen('track', 'Conversion', {
      eventName: 'purchase',
      value: order.total
    });
    
    // Show confirmation
  }
}

Trial Activation

async function startTrial(plan) {
  const trial = await activateTrial(plan);
  
  if (trial.active) {
    idlen('track', 'Conversion', {
      eventName: 'trial_start',
      value: plan.monthlyPrice // Track potential value
    });
  }
}
Best Practice: Only fire conversion events after the action is confirmed successful (e.g., after API response), not on button click.
Copyright © 2026