Donorbox now provides a way to pass donation details to  conversion tracking scripts like Facebook Pixel and Google Adwords conversion tracking. To enable this feature, Donorbox initializes a global JavaScript ('DONATION') object which will contain the 'donation' object after the successful donation is made. Thus DONORBOX.donation will be available after the donation tracking scripts to leverage the benefit of conversion tracking scripts.

Below are the examples illustrating the use of the JavaScript object for fetching donation details in conversion tracking scripts:

Facebook Pixel Tracking Example

  s.parentNode.insertBefore(t,s)}(window, document,'script',

  fbq('init', 'XXXXXXXXX', {
    fn: DONORBOX.donation.firstName,
    ln: DONORBOX.donation.lastName,

  fbq('track', 'Purchase', {
    value: DONORBOX.donation.amount,
    currency: DONORBOX.donation.currency
<img height="1" width="1" style="display:none" src=""/>

Adwords Conversion Tracking Example

<script async src=""></script>
  window.dataLayer = window.dataLayer || [];
  function gtag(){dataLayer.push(arguments);}
  gtag('js', new Date());
  gtag('config', 'AW-XXXXXXXXX');
  gtag('event', 'conversion', {
    'value': DONORBOX.donation.amount,
    'currency': DONORBOX.donation.currency,