Skip to main content

Meta Pixel

Gerai Digital linked to Meta Pixel

Analytics & Ads add-on

This is part of the Analytics & Ads add-on, RM 12 a month on any plan and included in Tree. Without it, these settings are locked.

Connect a store to your Meta Pixel to see which of your Facebook and Instagram ads lead to sales. Meta also uses it to show your ads to people more likely to buy.

You only need your pixel ID. Gerai Digital adds Meta's pixel to your store for you, and tells Meta when a shopper:

What the shopper doesMeta's event
Opens any pagePageView
Opens a productViewContent
Adds to cartAddToCart
Starts checkoutInitiateCheckout
Places an orderPurchase, with the order total

An order counts as a purchase once it's paid. Orders paid by bank transfer or cash on delivery count when they're placed. Each order counts once, even if the shopper opens its page again.

The pixel is free. You only pay Meta for ads you choose to run.

What you need​

A Meta business portfolio with a pixel. Meta Events Manager now calls a pixel a dataset, and its dataset ID is your pixel ID.

Don't have one yet? Create it in Meta Events Manager:

  1. Open Meta Events Manager.

  2. Check the business portfolio at the top right. It should be your business, so the dataset belongs to it. If you have more than one, pick the right one from the list.

    The business portfolio picker at the top right of Meta Events Manager

  3. Choose Connect data.

    The Events Manager overview, with Connect data at the top of the menu

  4. Pick Web and choose Next.

    The Connect a new data source window, with Web picked

  5. Give the dataset a name, such as your store's name, and choose Create.

    The Create a new dataset window: a name field, then Create

  6. Meta then asks how to connect your web data. Close that window. You don't need Meta's code or its partners, only the ID.

    The Connect your web data window, with the close button at the top right

Find your pixel ID​

  1. Open Meta Events Manager and check the business portfolio at the top right.

  2. Choose Datasets on the left.

  3. Find your dataset in the list. Its ID is shown under its name.

    The Datasets list, with the dataset's ID under its name

  4. Copy the ID. It's only numbers, about 15 or 16 of them.

You can also open the dataset's Settings tab and copy the Dataset ID from there.

The dataset's Settings tab, with the Dataset ID under Details

You don't need Meta's code

Meta also offers a code snippet to paste into your website. Skip it. Gerai Digital writes it into your store for you, using your pixel ID.

Connect it to your store​

  1. In your Gerai Digital dashboard, open the store and choose the Settings tab.
  2. Choose Analytics & Ads, then the Meta Pixel tab.
  3. Paste your pixel ID into Pixel ID and choose Save.

Cookies and your shoppers​

The Meta Pixel tracks your shoppers with cookies

Once connected, Meta sets cookies in your shoppers' browsers to track their visits and purchases. Your store asks shoppers to Accept or Decline cookies at the bottom of the page, in English or Bahasa Melayu. The Meta Pixel only starts after they accept, so shoppers who decline aren't counted.

You are responsible for telling your shoppers how you use their data. We recommend mentioning the Meta Pixel on your store's own privacy page.

Check it's working​

In Meta Events Manager, choose Datasets, pick your dataset and open Test events. Enter your store's address, open it, then view a product and add it to your cart. The events show up in Test events within a minute.

Visits from the template editor's preview aren't counted, so editing your store doesn't send anything to Meta.

See reports in Gerai Digital​

You can also see what this store's pixel recorded in its Analytics tab in Gerai Digital, next to Settings, under Meta Pixel. It shows page views, product views, add to cart, checkouts and purchases against the period before, how many shoppers go from viewing a product to buying, and page views per day, for the last 7, 28 or 90 days.

To turn it on, give Gerai Digital a token that can read your pixel. Meta makes these for a system user, a login for an app rather than a person. It takes a few minutes, and you only do it once.

Meta changes these screens often

If a button has a slightly different name, look for the closest match. The steps stay the same.

1. Add a system user​

  1. Open Meta Business settings.
  2. Under Users, choose System users, then Add.
  3. Name it Gerai Digital, pick the Employee role and choose Create system user.

2. Give it your pixel​

  1. With the system user picked, choose Assign assets.
  2. Choose Datasets on the left. Meta lists newer pixels there, so Pixels can say No business assets found.
  3. Tick your store's dataset and turn on Full control (Meta may call it Manage dataset).
  4. Choose Assign assets. The dataset now shows under the system user's assigned assets with Full access.

Dataset not in the list? Check the business portfolio at the top left is the one that owns it, the same as in Events Manager. Or do it from the dataset's side: in Business settings, open Data sources › Datasets, pick your dataset, choose Assign people (or Add people), and pick the system user with full control.

3. Create a Meta app​

Meta only makes tokens for an app, so you need one in your business portfolio. If you already have one there, see Already have an app? below.

  1. Open Meta for Developers and choose Create App.

    The Apps page in Meta for Developers, with Create App at the top right

  2. Give the app a name, such as your store's name. Check the contact email, then choose Next.

    The App details step: App name, then App contact email

  3. Pick Measure ad performance data with Analytics & Ads API and choose Next. Don't create the app without a use case: it can't give the token any permissions.

  4. Pick the business portfolio that owns your pixel and choose Next. It doesn't need to be verified.

    The Business step: a list of your business portfolios to pick from

  5. Meta shows no requirements. Choose Next.

    The Requirements step: No requirements identified

  6. Check the overview and choose Create app.

    The Overview step, with Create app at the bottom right

  7. Meta asks for your Facebook password again. Enter it and choose Submit.

    The Please re-enter your password window

You don't need to set anything else up in the app.

Already have an app?​

Your app needs the same use case, or Meta won't let the token have any permissions.

  1. Open the app in Meta for Developers. Choose Use cases on the left, then Add use case.

  2. Tick Measure ad performance data with Analytics & Ads API.

    The Add more use cases window, with Measure ad performance data with Analytics & Ads API ticked

  3. Meta says extra steps are needed before publishing the app. You don't need to publish it, so choose Add to app, then Save.

    The Extra steps required after adding this use case window, with Add to app at the bottom right

4. Generate a token​

  1. Back in System users, pick Gerai Digital and choose Generate token.

  2. Pick your app.

  3. Under Token expiration, choose Never.

  4. Under Select permissions, tick ads_read, ads_management and business_management, then choose Generate token. Meta only shares a pixel's numbers with tokens that have ads_management.

    The Assign permissions step, with ads_management, ads_read and business_management ticked

    No permissions to pick? Your app is missing the use case. See Already have an app?

  5. Choose Copy to copy the token. Meta shows it only once.

    The Token created step, with Copy next to the token

5. Add it to your store​

  1. In Gerai Digital, open the store and choose Settings › Analytics & Ads › Meta Pixel.
  2. Under Show reports in Gerai Digital, paste the token into Access token and choose Save and check.
  3. When you see Reports connected, open the store's Analytics tab and choose Meta Pixel.

If the check says the token can't read the pixel, make sure you gave the system user your pixel in step 2.

Because Meta asks for ads_management, the token could also change your ads. Gerai Digital only uses it to read this store's pixel, keeps it encrypted and never shows it again. To stop it, choose Disconnect under Show reports in Gerai Digital, or remove the system user in Meta Business settings.

See your ad results (beta)​

If you run Facebook or Instagram ads, the same tab can also show Ad results above what the pixel recorded: impressions, reach, clicks, amount spent, purchases from your ads and return on ad spend, against the period before, and the campaigns that spent most. Nothing in Gerai Digital can change or spend on your ads; it only reads them.

  1. In Meta Business settings, open Accounts › Ad accounts, pick your ad account and copy its ID (only numbers).
  2. Under Users › System users, pick Gerai Digital, choose Assign assets › Ad accounts, tick your ad account and turn on View performance (or full control). Choose Assign assets.
  3. In Gerai Digital, under Show reports in Gerai Digital, paste the ID into Ad account ID and choose Save and check. You don't need a new token.

Ad results are new and marked BETA. They only show numbers once a campaign has run. If they look wrong, email hello@chelevenild.my with your ad account ID.

When the numbers show up​

Reports update every hour. Choose Refresh at the top of the tab to get the latest now. The numbers count every visit, from your ads or not. Shoppers who block Meta or cookies aren't counted, so they can be lower than your orders.

Stop tracking​

Go back to Settings › Analytics & Ads › Meta Pixel, clear Pixel ID and choose Save. Meta's pixel is removed from your store.