Docs
← Back to site

On your own WordPress

1 min readUpdated November 11, 2026
// Any website of yours, by id or by one of its domains
nahnu_analytics_send_event( 'example.com', 'Lead won', array(
    'props'      => array( 'plan' => 'pro' ),
    'revenue'    => array( 'amount' => 490, 'currency' => 'USD' ),
    'url'        => 'https://example.com/thanks',
    'ip'         => '203.0.113.9',   // optional: joins this visitor's visit
    'user_agent' => 'Mozilla/5.0 …', // optional, with ip
) );
HookKindWhat for
nahnu_analytics/eventfilterChange or drop (false) an event before sending
nahnu_analytics/event_sentactionAfter sending
nahnu_analytics/direct_readsfilterReturn false to make every dashboard read through WordPress instead of straight from Cloudflare
nahnu_analytics_heatmap_originfilterWhere a website’s pages are fetched from for heatmaps (a staging copy, a test server)
nahnu_analytics_consent_essentialfilterReturn false to let consent tools on your own WordPress hold the stats back
nahnu_analytics/js_stringsfilterTranslations for the dashboard and portal apps
nahnu_analytics/booted, nahnu_analytics/site_deleted, nahnu_analytics/client_deleted, nahnu_analytics/site_domains_saved, nahnu_analytics/tracking_settings_saved, nahnu_analytics/upgradedactionsReact to changes

Was this helpful?