# Mi Pixel Integration Tutorial

# Mi Ads Pixel

Mi Pixel is a piece of JavaScript code for tracking user behavior on websites.When launching web-based products, advertisers can integrate Mi Pixel real-time data postbacks with the ad platform to support ad campaign performance analysis and optimization.

# How to set up and verify a Mi Ads Pixel

# Instructions

We currently support the following methods for setting up a Mi Ads Pixel:

  • Custom coding: Create events by coding them into your website.This option lets you configure events very flexibly.Note: This option requires special coding skills. It should be handled by a specialized developer.

# How to set up a Mi Ads Pixel

To set up a Mi Ads Pixel, follow the steps below:


  1. Log in to the Mi Ads Xiaomi overseas marketing platform and select your account, then go to "Asset Center".
  2. Click "Pixel".
  3. Click "New folder".
  4. Set the basic information
  5. Set your Pixel name and link the URL.
  6. Select "Developer Mode"
  7. Then click "Next".
  8. Follow the prompts to add the Pixel base code to your website.

Note: You also have the option to integrate using a third-party platform or tool such as Google Tag Manager.


  1. Use “Send test traffic” to verify whether the code is correctly installed on your website.
  2. Then click on Next.
  3. Click “Manage events” to add or delete predefined standard events, such as page views, registrations, payments, etc.
  4. Follow the prompts to add the corresponding event code to your website.
  Note: You can also verify your Pixel and event settings using the following methods:
  • Download the Mi Ads Pixel Helper from the Chrome Web Store and verify whether the Mi Ads Pixel is installed correctly and the events are reported correctly.

  1. Click the "Complete" button.

# Follow-up actions

If you've previously created a Pixel on the Mi Ads overseas ad platform but haven't yet added the Pixel base code to your website, you can return to the Settings page by following the steps below:

  1. Click "Asset Center".
  2. Click "Pixel".
  3. Locate the previously created Pixel and click “Edit.”

# Supported standard events

Our pre-installation supports the following events:

Event name
Event code
Event description
Recommended parameters
Page view
page_view

page_view is triggered when a user visits a new page on your website.Every page of your website triggers this event

Viewing specific webpages

view_content
This event is triggered when a user visits a specific page

content_id: The viewed content's unique ID
Button click
button_click
When a user clicks a button

Registration
registration
This event is triggered when a user completes a registration

Purchase

purchase

This event is sent when a user completes a purchase

content_type: The type of product
quantity: The number of items added to the shopping cart
description: The description of the product
item: The item added to the shopping cart
currency: The monetary currency
value: The monetary value of the product
Form/information submission
lead

This event is triggered when a prospective user expresses interest (typically by submitting a form).For example, when a user fills out a contact form to receive more product-related information.This event must be sent

Ad click
ad_click
This event is triggered when a user clicks on ad

Add to cart

add_to_cart

This event is triggered when a user adds an item to their shopping cart

content_type: The type of product
quantity: The number of items added to the shopping cart
description: The description of the product
item: The item added to the shopping cart
currency: The monetary currency
value: The monetary value of the product

Add to wishlist
add_to_wishlist
This event is triggered when a user adds an item to their wish list

Add payment information
add_payment_info

This event is triggered when a user adds payment information during checkout

Subscribe
subscribe



# How to integrate Mi Ads Pixel in Google Tag Manager

How to set up Mi Ads Pixel with Google Tag Manager in Mi Ads Event Manager?