SDP Platform

How to Add Meta Pixel to Your SDP Website

Published on 15 October, 2026
How to Add Meta Pixel to Your SDP Website - SDP Platform tutorial showing the Header Scripts editor

Meta Pixel lets you measure visits and conversions from your Facebook and Instagram ads. On SDP Platform you add it once in your website's global code, and it loads on every page. This guide follows Meta's official steps in Set up and install a Meta Pixel.

What you need

Step 1: Open Events Manager and click Connect data

Open Meta Events Manager and make sure your business is selected in the top-right menu. Then click Connect data in the left menu.

Meta Events Manager overview showing the Datasets panel and the Connect data button
Events Manager Overview. Click Connect data to add a new data source.

Step 2: Choose Web

In Connect a new data source, select Web and click Next. Give your dataset a name, such as your website's name, and continue.

Connect a new data source dialog in Meta Events Manager with Web selected
Select Web, then click Next.

Step 3: Choose to add the code yourself

In Set up Meta Pixel, choose Add Meta Pixel code to website yourself and click Next.

Set up Meta Pixel dialog with Add Meta Pixel code to website yourself selected
Choose Add Meta Pixel code to website yourself.

Step 4: Copy the base code

On the Copy base code step, click Copy code. The code looks like this, with your own Pixel ID in place of YOUR_PIXEL_ID:

Copy base code step in Meta Pixel setup with the Copy code button
Click Copy code to copy your Meta Pixel base code.
<!-- Meta Pixel Code -->
<script>
!function(f,b,e,v,n,t,s)
{if(f.fbq)return;n=f.fbq=function(){n.callMethod?
n.callMethod.apply(n,arguments):n.queue.push(arguments)};
if(!f._fbq)f._fbq=n;n.push=n;n.loaded=!0;n.version='2.0';
n.queue=[];t=b.createElement(e);t.async=!0;
t.src=v;s=b.getElementsByTagName(e)[0];
s.parentNode.insertBefore(t,s)}(window, document,'script',
'https://connect.facebook.net/en_US/fbevents.js');
fbq('init', 'YOUR_PIXEL_ID');
fbq('track', 'PageView');
</script>
<noscript><img height="1" width="1" style="display:none"
src="https://www.facebook.com/tr?id=YOUR_PIXEL_ID&ev=PageView&noscript=1"
/></noscript>
<!-- End Meta Pixel Code -->

Step 5: Paste the code into Header Scripts in SDP

1. Sign in to the SDP dashboard. On My Websites, click your website's card to open it.

SDP dashboard My Websites list showing website cards, including the SDP Platform card
My Websites: click your website card to open it.

2. In the website editor, open the Advanced tab, then choose Scripts & Robots.txt. You'll see three editors: Header Scripts, Footer Scripts and Robots.txt.

SDP website editor with the Advanced tab open on the Scripts & Robots.txt page, showing the Header Scripts, Footer Scripts and Robots.txt editors
Advanced → Scripts & Robots.txt. Header Scripts is the first editor.

3. In Header Scripts, paste the Meta base code below any code that's already there. Don't delete or change existing scripts. Then click the Save button for that editor (each editor has its own Save button).

Header Scripts editor with an existing script on line 1 and the Meta Pixel Code pasted below it, with the Save button above the editor
Meta Pixel Code pasted below the existing script in Header Scripts. Click Save.

Header Scripts load on every page of your website, so the pixel now tracks all pages.

The Advanced tab is also where you manage other site-wide code. For site-wide styles, see How to Add Custom CSS.

Step 6: Test that it works

In Meta Events Manager, open your dataset and go to the Test events tab. Choose Website, enter your website address, open it, and browse a page or two. You should see PageView events marked Processed.

Meta Events Manager Test events tab showing PageView events received from the website
Test events: PageView events received from the website.

You can also install the Meta Pixel Helper Chrome extension and visit your site. It shows whether the pixel is found and firing.

Allow a few minutes. New pixels can take a while to show events. Ad blockers and privacy browsers can also stop the pixel, so test in a normal browser window without them.

Optional: Track standard events such as Lead

PageView is tracked on every page automatically. To track actions such as form submissions, add a standard event, for example fbq('track', 'Lead');, where the action happens. See Meta's standard events reference and Meta Pixel get started guide.

How to undo it

To remove the pixel, open Advanced → Scripts & Robots.txt → Header Scripts and delete everything from <!-- Meta Pixel Code --> to <!-- End Meta Pixel Code -->, then click Save. SDP keeps an edit history for these scripts (the clock icon next to Save), so you can also restore a previous version of Header Scripts. Before bigger changes, it's a good idea to download a website backup.

Related guides