{"id":5510,"date":"2024-04-18T14:39:17","date_gmt":"2024-04-18T05:39:17","guid":{"rendered":"https:\/\/help-ads.smartnews.com\/?p=5510"},"modified":"2025-07-14T14:50:30","modified_gmt":"2025-07-14T05:50:30","slug":"item-3056","status":"publish","type":"post","link":"https:\/\/help-ads.smartnews.com\/en\/item-3056\/","title":{"rendered":"Setting up Pixels and events"},"content":{"rendered":"\n<h2 class=\"wp-block-heading\">Overview<\/h2>\n\n\n\n<p>SmartNews Pixels are small snippets of code can be added to all of the pages where you wish to track user behavior. You can measure the effectiveness of your conversion funnel and calculate your exact return on investment from SmartNews ads.<\/p>\n\n\n\n<h4 class=\"wp-block-heading\">General workflow for setting up SmartNews Pixels:<\/h4>\n\n\n\n<h6 class=\"wp-block-heading\"><i>1<\/i><span>Create a new Pixel from the Events tab in Ads Manager.<\/span><\/h6>\n\n\n\n<h6 class=\"wp-block-heading\"><i>2<\/i><span>Set up an event which will be used to track the specific behavior we want to track, for example, \u201cAdd to Cart\u201d.<\/span><\/h6>\n\n\n\n<h6 class=\"wp-block-heading\"><i>3<\/i><span>Add the Pixel\u2019s base code to all the pages where you want to track user behavior.<\/span><\/h6>\n\n\n\n<h6 class=\"wp-block-heading\"><i>4<\/i><span>Add the event code to the page that will be used to track the behavior, such as the checkout end page. Alternatively, if you wish to track events from a clickable element like a button or link, you can set up events to use a URL configuration instead of an event code.<\/span><\/h6>\n\n\n\n<h6 class=\"wp-block-heading\"><i>5<\/i><span>We recommend you set up multiple events to track the full funnel of conversions. SmartNews provides a <a href=\"https:\/\/help-ads.smartnews.com\/en\/item-3056\/#i4\" title=\"\">set of 22 standard events<\/a> right out of the box.<\/span><\/h6>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"650\" src=\"https:\/\/help-ads.smartnews.com\/wp-content\/uploads\/2024\/09\/image-53-1024x650.png\" alt=\"\" class=\"wp-image-4102\" srcset=\"https:\/\/help-ads.smartnews.com\/wp-content\/uploads\/2024\/09\/image-53-1024x650.png 1024w, https:\/\/help-ads.smartnews.com\/wp-content\/uploads\/2024\/09\/image-53-300x190.png 300w, https:\/\/help-ads.smartnews.com\/wp-content\/uploads\/2024\/09\/image-53-768x487.png 768w, https:\/\/help-ads.smartnews.com\/wp-content\/uploads\/2024\/09\/image-53-1536x974.png 1536w, https:\/\/help-ads.smartnews.com\/wp-content\/uploads\/2024\/09\/image-53-2048x1299.png 2048w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<p>Capturing the checkout conversion funnel with a SmartNews Pixel<\/p>\n\n\n\n<h4 class=\"wp-block-heading\">Three ways to set up events:<\/h4>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Add an event code snippet to the <strong><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-theme-1-color\">&lt;body&gt;<\/mark><\/strong> section of the web page you wish to track.<\/li>\n\n\n\n<li>Add an event code snippet together with a Pixel base code to the <strong><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-theme-1-color\">&lt;head&gt;<\/mark><\/strong> section of the web page you wish to track.<\/li>\n\n\n\n<li>Use the <strong>URL configuration<\/strong> setting to map an event to your custom URL structure.<\/li>\n<\/ul>\n\n\n\n<h2 class=\"wp-block-heading\">Pixel creation in Ads Manager<\/h2>\n\n\n\n<h6 class=\"wp-block-heading\"><i>1<\/i><span>Go to Events tab in Ads Manager and select Create new Pixel.<\/span><\/h6>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"308\" src=\"https:\/\/help-ads.smartnews.com\/wp-content\/uploads\/2024\/09\/image-54-1024x308.png\" alt=\"\" class=\"wp-image-4103\" srcset=\"https:\/\/help-ads.smartnews.com\/wp-content\/uploads\/2024\/09\/image-54-1024x308.png 1024w, https:\/\/help-ads.smartnews.com\/wp-content\/uploads\/2024\/09\/image-54-300x90.png 300w, https:\/\/help-ads.smartnews.com\/wp-content\/uploads\/2024\/09\/image-54-768x231.png 768w, https:\/\/help-ads.smartnews.com\/wp-content\/uploads\/2024\/09\/image-54.png 1431w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<h6 class=\"wp-block-heading\"><i>2<\/i><span>Provide a name for your new Pixel.<\/span><\/h6>\n\n\n\n<h6 class=\"wp-block-heading\"><i>3<\/i><span>Select Download code and have your web development team <a href=\"https:\/\/help-ads.smartnews.com\/en\/item-3056\/#i3\" title=\"\">implement the Pixel base code<\/a> on your website.<\/span><\/h6>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"608\" height=\"1024\" src=\"https:\/\/help-ads.smartnews.com\/wp-content\/uploads\/2024\/09\/image-55-608x1024.png\" alt=\"\" class=\"wp-image-4104\" srcset=\"https:\/\/help-ads.smartnews.com\/wp-content\/uploads\/2024\/09\/image-55-608x1024.png 608w, https:\/\/help-ads.smartnews.com\/wp-content\/uploads\/2024\/09\/image-55-178x300.png 178w, https:\/\/help-ads.smartnews.com\/wp-content\/uploads\/2024\/09\/image-55-768x1293.png 768w, https:\/\/help-ads.smartnews.com\/wp-content\/uploads\/2024\/09\/image-55.png 802w\" sizes=\"auto, (max-width: 608px) 100vw, 608px\" \/><\/figure>\n\n\n\n<h2 class=\"wp-block-heading\">Adding Pixel base codes to your site<\/h2>\n\n\n\n<p>The base code should be added to the header section of the advertiser\u2019s website. As a best practice, we highly recommend that you add the Pixel base code between the opening and closing <strong><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-theme-1-color\">&lt;head&gt;<\/mark><\/strong> tags on every page where you will be tracking visitor actions. Most companies add it to their website\u2019s persistent header so that it can be used on all pages. Placing the code within the <strong><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-theme-1-color\">&lt;head&gt;<\/mark><\/strong> tags also reduces the chances of browsers or third-party code blocking the Pixel\u2019s function.<\/p>\n\n\n\n<p>Finally, it\u2019s best to implement just one set of Pixel codes per website. If you plan to implement more than one set of Pixel codes on a single website, please check with us first.<\/p>\n\n\n\n<div class=\"wp-block-snow-monkey-blocks-accordion smb-accordion\">\n<div class=\"wp-block-snow-monkey-blocks-accordion-item smb-accordion__item\"><input type=\"checkbox\" class=\"smb-accordion__item__control\" aria-label=\"A accordion item\" \/><div class=\"smb-accordion__item__title\"><span class=\"smb-accordion__item__title__label\">Example Pixel base code<\/span><div class=\"smb-accordion__item__title__icon\"><i class=\"fa-solid fa-angle-down\"><\/i><\/div><\/div><div class=\"smb-accordion__item__body is-layout-constrained wp-block-snow-monkey-blocks-accordion-item-is-layout-constrained\">\n<pre id=\"block-8b563257-79f8-4a70-af5f-81dc63a7cefc\" class=\"wp-block-code\"><code>&lt;!-- SmartNews Ads Pixel Code --&gt;\n\n&lt;script type=\"text\/javascript\"&gt;\n\n!function(){if(window.SmartnewsAds=window.SmartnewsAds||{},!window.SmartnewsAds.p){var e=window.SmartnewsAds.p=function(){e.callMethod?e.callMethod.apply(e,arguments):e.queue.push(arguments)};e.push=e,e.version=\"1.0.1\",e.queue=&#091;];var n=document.createElement(\"script\");n.async=!0,n.src=\"\/\/cdn.smartnews-ads.com\/i\/pixel.js\";var s=document.getElementsByTagName(\"script\")&#091;0];s.parentNode.insertBefore(n,s)}}();\n\nSmartnewsAds.p(\"&#091;pixel ID]\", \"PageView\");\n\n&lt;\/script&gt;\n\n&lt;noscript&gt;\n\n&lt;img height=\"1\" width=\"1\" style=\"display:none;\" alt=\"\" src=\"https:\/\/i.smartnews-ads.com\/p?id=&#091;pixel ID]&amp;e=PageView\" \/&gt;\n\n&lt;\/noscript&gt;<\/code><\/pre>\n<\/div><\/div>\n<\/div>\n\n\n\n<h3 class=\"wp-block-heading\">Setting up event tracking<\/h3>\n\n\n\n<h4 class=\"wp-block-heading\">Three ways to set up events:<\/h4>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Add the Pixel base code to the <strong><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-theme-1-color\">&lt;head&gt;<\/mark><\/strong> section across your website and various event codes on web pages where you wish to track conversion events.<\/li>\n\n\n\n<li>Add the Pixel base code together with event codes in the <strong><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-theme-1-color\">&lt;body&gt;<\/mark><\/strong> section on web pages where you wish to track conversion events.<\/li>\n\n\n\n<li>Add just the base code to the <strong><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-theme-1-color\">&lt;head&gt;<\/mark><\/strong> section and use the Events Manager\u2019s URL configuration tool to set up event tracking.<\/li>\n<\/ul>\n\n\n\n<h3 class=\"wp-block-heading\">Adding event codes to your web pages<\/h3>\n\n\n\n<p>Add a single line of event code to the web pages where you wish to track conversions. For example, the event code for the Purchase event is <strong><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-theme-1-color\">SmartnewsAds.p(&#8220;[pixel ID]&#8221;, &#8220;Purchase&#8221;)<\/mark><\/strong>. Add this line to pages where customers can make purchases. Here\u2019s an example of a SmartNews Pixel base code with a \u201cPurchase\u201d event:<\/p>\n\n\n\n<pre id=\"block-8b563257-79f8-4a70-af5f-81dc63a7cefc\" class=\"wp-block-code\"><code>&lt;!-- SmartNews Ads Pixel Code --&gt;\n&lt;script type=\"text\/javascript\"&gt;\n!function(){if(window.SmartnewsAds=window.SmartnewsAds||{},!window.SmartnewsAds.p){var e=window.SmartnewsAds.p=function(){e.callMethod?e.callMethod.apply(e,arguments):e.queue.push(arguments)};e.push=e,e.version=\"1.0.1\",e.queue=&#091;];var n=document.createElement(\"script\");n.async=!0,n.src=\"https**:**\/\/cdn.smartnews-ads.com\/i\/pixel.js\";var s=document.getElementsByTagName(\"script\")&#091;0];s.parentNode.insertBefore(n,s)}}();\nSmartnewsAds.p(\"**&#091;pixel ID]**\", \"PageView\");\nSmartnewsAds.p(\"**&#091;pixel ID]**\", \"Purchase\");\n&lt;\/script&gt;\n&lt;noscript&gt;\n&lt;img height=\"1\" width=\"1\" style=\"display:none;\" alt=\"\" src=\"https:\/\/i.smartnews-ads.com\/p?id=**&#091;pixel ID]**&amp;e=PageView\" \/&gt;\n&lt;img height=\"1\" width=\"1\" style=\"display:none;\" alt=\"\" src=\"https:\/\/i.smartnews-ads.com\/p?id=**&#091;pixel ID]**&amp;e=Purchase\" \/&gt;\n&lt;\/noscript&gt;<\/code><\/pre>\n\n\n\n<h3 class=\"wp-block-heading\">Use URL configuration to track events<\/h3>\n\n\n\n<p>In addition to Pixel event codes, URL configuration can be used to define how an event is tracked. On the event setup screen, select <strong>URL configuration<\/strong> and define an URL rule by specifying a URL match type and entering the corresponding URL information.<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"659\" src=\"https:\/\/help-ads.smartnews.com\/wp-content\/uploads\/2024\/09\/image-56-1024x659.png\" alt=\"\" class=\"wp-image-4105\" srcset=\"https:\/\/help-ads.smartnews.com\/wp-content\/uploads\/2024\/09\/image-56-1024x659.png 1024w, https:\/\/help-ads.smartnews.com\/wp-content\/uploads\/2024\/09\/image-56-300x193.png 300w, https:\/\/help-ads.smartnews.com\/wp-content\/uploads\/2024\/09\/image-56-768x494.png 768w, https:\/\/help-ads.smartnews.com\/wp-content\/uploads\/2024\/09\/image-56-1536x989.png 1536w, https:\/\/help-ads.smartnews.com\/wp-content\/uploads\/2024\/09\/image-56-2048x1319.png 2048w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<p>A unique combination of URL match type and URL can be used to define how a standard event is tracked. Three match types are available:<\/p>\n\n\n\n<h5 class=\"wp-block-heading\">URL is<\/h5>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Our system will attempt to do an exact match to the URL provided and record the corresponding event. For example, whenever the exact URL <strong><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-theme-1-color\">www.domain.com\/purchase-complete<\/mark><\/strong> is loaded, a Purchase event is recorded.<\/li>\n<\/ul>\n\n\n\n<h5 class=\"wp-block-heading\">URL starts with<\/h5>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Any URL that starts with the string of texts provided will trigger this rule. For example, a URL that starts with <strong><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-theme-1-color\">www.domain.com\/search<\/mark><\/strong> could be used to track the actions of users searching products and going to a search result page if your search result page has the URL format of <strong><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-theme-1-color\">www.domain.com\/search\/keywords<\/mark><\/strong>.<\/li>\n<\/ul>\n\n\n\n<h5 class=\"wp-block-heading\">URL contains<\/h5>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Any URL that contains the entered string will trigger this rule and record the corresponding event.<\/li>\n<\/ul>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"756\" height=\"506\" src=\"https:\/\/help-ads.smartnews.com\/wp-content\/uploads\/2024\/09\/image-57.png\" alt=\"\" class=\"wp-image-4107\" srcset=\"https:\/\/help-ads.smartnews.com\/wp-content\/uploads\/2024\/09\/image-57.png 756w, https:\/\/help-ads.smartnews.com\/wp-content\/uploads\/2024\/09\/image-57-300x201.png 300w\" sizes=\"auto, (max-width: 756px) 100vw, 756px\" \/><\/figure>\n\n\n\n<p>SmartNews automatically detects the validity of each rule. If two or more rules have conflicting logic, the setup screen displays an error message, and the rule cannot be saved. Once a URL configuration rule is successfully saved, the event and rule appear in the Events tab.<\/p>\n\n\n\n<p>You can edit or remove a URL configuration at any time. If you&#8217;ve added a Pixel event code to your website and later decide to switch to a URL configuration rule for the same event, the URL configuration rule will be used to track events in Ads Manager, replacing the event code. If you remove the URL configuration, event tracking will revert to the Pixel event code, provided it&#8217;s correctly installed on your website.<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"276\" src=\"https:\/\/help-ads.smartnews.com\/wp-content\/uploads\/2024\/09\/Screen-Shot-2023-12-14-at-9.55.22-PM-1024x276.png\" alt=\"\" class=\"wp-image-4108\" srcset=\"https:\/\/help-ads.smartnews.com\/wp-content\/uploads\/2024\/09\/Screen-Shot-2023-12-14-at-9.55.22-PM-1024x276.png 1024w, https:\/\/help-ads.smartnews.com\/wp-content\/uploads\/2024\/09\/Screen-Shot-2023-12-14-at-9.55.22-PM-300x81.png 300w, https:\/\/help-ads.smartnews.com\/wp-content\/uploads\/2024\/09\/Screen-Shot-2023-12-14-at-9.55.22-PM-768x207.png 768w, https:\/\/help-ads.smartnews.com\/wp-content\/uploads\/2024\/09\/Screen-Shot-2023-12-14-at-9.55.22-PM.png 1269w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<h2 class=\"wp-block-heading\">SmartNews standard events<\/h2>\n\n\n\n<p>Below is a list of 22 standard event types for user behavior tracking available from the Events tab.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Most commonly used event types<\/h3>\n\n\n\n<figure class=\"wp-block-table has-small-font-size\"><table class=\"has-fixed-layout\"><thead><tr><th><strong>Event name<\/strong><\/th><th><strong>Recommended properties<\/strong><\/th><th><strong>Example event code<\/strong><\/th><th><strong>Event description<\/strong><\/th><\/tr><\/thead><tbody><tr><td><strong>AddPaymentInfo<\/strong><\/td><td>content_ids, contents, currency, value<\/td><td>SmartnewsAds.p(&#8220;your pixel tag ID&#8221;, &#8220;AddPaymentInfo&#8221;)<\/td><td>When payment information is added in the checkout flow.<br><br>Example: Someone clicks on a [Save billing information] button.<\/td><\/tr><tr><td><strong>AddToCart<\/strong><\/td><td>content_ids, content_type, contents, currency, valuecontent_ids are required for Dynamic Ads<\/td><td>SmartnewsAds.p(&#8220;your pixel tag ID&#8221;, &#8220;AddToCart&#8221;)<\/td><td>When a product is added to the shopping cart.<br><br>Example: Someone clicks on an [Add to cart] button.<\/td><\/tr><tr><td><strong>AddToWishList<\/strong><\/td><td>content_ids, contents, currency, value<\/td><td>SmartnewsAds.p(&#8220;your pixel tag ID&#8221;, &#8220;AddToWishlist&#8221;)<\/td><td>When a product is added to a Wishlist.<br><br>Example: Someone clicks on an [Add to Wishlist] button.<\/td><\/tr><tr><td><strong>Booking<\/strong><\/td><td><\/td><td>SmartnewsAds.p(&#8220;your pixel tag ID&#8221;, &#8220;Booking&#8221;)<\/td><td>When a reservation or booking is made for a service, such as a hotel, flight, or event ticket.<\/td><\/tr><tr><td><strong>CompleteRegistration<\/strong><\/td><td>currency, value<\/td><td>SmartnewsAds.p(&#8220;your pixel tag ID&#8221;, &#8220;CompleteRegistration&#8221;)<\/td><td>When a registration form is completed.<br><br>Example: Someone submits a completed subscription or signup form.<\/td><\/tr><tr><td><strong>Contact<\/strong><\/td><td><\/td><td>SmartnewsAds.p(&#8220;your pixel tag ID&#8221;, &#8220;Contact&#8221;)<\/td><td>When someone initiates contact with your business via telephone, SMS, email, chat, etc.<br><br>Example: Someone submits a question about a product.<\/td><\/tr><tr><td><strong>CustomizeProduct<\/strong><\/td><td><\/td><td>SmartnewsAds.p(&#8220;your pixel tag ID&#8221;, &#8220;CustomizeProduct&#8221;)<\/td><td>When someone customizes a product.<br><br>Example: Someone selects the color of a T-shirt.<\/td><\/tr><tr><td><strong>Donate<\/strong><\/td><td><\/td><td>SmartnewsAds.p(&#8220;your pixel tag ID&#8221;, &#8220;Donate&#8221;)<\/td><td>When someone donates funds to your organization or cause.<br><br>Example: Someone adds a donation for the Humane Society to their cart.<\/td><\/tr><tr><td><strong>Download<\/strong><\/td><td><\/td><td>SmartnewsAds.p(&#8220;your pixel tag ID&#8221;, &#8220;Download&#8221;)<\/td><td>When a file, app, or other piece of digital content is downloaded.<br><br>Example: Someone clicks a [Download] button for a white paper.<\/td><\/tr><tr><td><strong>FindLocation<\/strong><\/td><td><\/td><td>SmartnewsAds.p(&#8220;your pixel tag ID&#8221;, &#8220;FindLocation&#8221;)<\/td><td>When someone searches for a location of your store via a website or app, intending to visit the physical location.<br><br>Example: Someone wants to find a specific product in a local store.<\/td><\/tr><tr><td><strong>InitiateCheckout<\/strong><\/td><td>content_ids, contents, currency, quantity, value<\/td><td>SmartnewsAds.p(&#8220;your pixel tag ID&#8221;, &#8220;InitiateCheckout&#8221;)<\/td><td>When someone enters the checkout flow prior to completing the checkout flow. Example: Someone clicks on a checkout button.<\/td><\/tr><tr><td><strong>Lead<\/strong><\/td><td>currency, valuecontent_ids are required for Dynamic Ads<\/td><td>SmartnewsAds.p(&#8220;your pixel tag ID&#8221;, &#8220;Lead&#8221;)<\/td><td>When a signup is completed or other event of interest is recorded. Example: Someone clicks on pricing or submits a lead form.<\/td><\/tr><tr><td><strong>Login<\/strong><\/td><td><\/td><td>SmartnewsAds.p(&#8220;your pixel tag ID&#8221;, &#8220;Login&#8221;)<\/td><td>When someone logs in to an existing account.<\/td><\/tr><tr><td><strong>Purchase<\/strong><\/td><td>content_ids, content_type, contents, currency, quantity, valuecontent_ids, currency, value are required for Dynamic Ads<\/td><td>SmartnewsAds.p(&#8220;your pixel tag ID&#8221;, &#8220;Purchase&#8221;)<\/td><td>When a purchase is made or checkout flow is completed.<br><br>Example: Someone has finished the purchase or checkout flow and lands on the purchase confirmation page.<\/td><\/tr><tr><td><strong>Schedule<\/strong><\/td><td><\/td><td>SmartnewsAds.p(&#8220;your pixel tag ID&#8221;, &#8220;Schedule&#8221;)<\/td><td>When someone books an appointment to visit one of your locations.<br><br>Example: Someone selects a date and time for a tennis lesson.<\/td><\/tr><tr><td><strong>Search<\/strong><\/td><td>content_ids, content_type, contents, currency, search_string, value<\/td><td>SmartnewsAds.p(&#8220;your pixel tag ID&#8221;, &#8220;Search&#8221;)<\/td><td>When a search is made.<br><br>Example: Someone searches for a product on your website.<\/td><\/tr><tr><td><strong>Share<\/strong><\/td><td><\/td><td>SmartnewsAds.p(&#8220;your pixel tag ID&#8221;, &#8220;Share&#8221;)<\/td><td>When someone shares content from your site or app via a share button or other mechanism.<\/td><\/tr><tr><td><strong>SignUp<\/strong><\/td><td><\/td><td>SmartnewsAds.p(&#8220;your pixel tag ID&#8221;, &#8220;SignUp&#8221;)<\/td><td>When someone signs up for an account (pre-registration) but may have not yet completed a full registration.<\/td><\/tr><tr><td><strong>StartTrial<\/strong><\/td><td>currency, predicted_ltv, value<\/td><td>SmartnewsAds.p(&#8220;your pixel tag ID&#8221;, &#8220;StartTrial&#8221;)<\/td><td>When someone starts a free trial of a product or service you offer.<br><br>Example: Someone starts a free trial for your game.<\/td><\/tr><tr><td><strong>SubmitApplication<\/strong><\/td><td><\/td><td>SmartnewsAds.p(&#8220;your pixel tag ID&#8221;, &#8220;SubmitApplication&#8221;)<\/td><td>When someone applies for an offered product, service, or program.<br><br>Example: Someone applies for a credit card, educational program, or job.<\/td><\/tr><tr><td><strong>SubmitForm<\/strong><\/td><td><\/td><td>SmartnewsAds.p(&#8220;your pixel tag ID&#8221;, &#8220;SubmitForm&#8221;)<\/td><td>When someone submits a form (e.g., contact form or survey) that is not covered by other events.<\/td><\/tr><tr><td><strong>Subscribe<\/strong><\/td><td>currency, predicted_ltv, value<\/td><td>SmartnewsAds.p(&#8220;your pixel tag ID&#8221;, &#8220;Subscribe&#8221;)<\/td><td>When someone applies to start a paid subscription for a product or service you offer.<br><br>Example: Someone subscribes to your streaming service.<\/td><\/tr><tr><td><strong>TimeSpent<\/strong><\/td><td><\/td><td>SmartnewsAds.p(&#8220;your pixel tag ID&#8221;, &#8220;TimeSpent&#8221;)<\/td><td>When the time a user spends on a page or screen is tracked and meets a threshold you define<\/td><\/tr><tr><td><strong>ViewContent<\/strong><\/td><td>content_ids, content_type, contents, currency, valuecontent_ids are reuiqred for Dynamic Ads<\/td><td>SmartnewsAds.p(&#8220;your pixel tag ID&#8221;, &#8220;ViewContent&#8221;)<\/td><td>A visit to a relevant web page (Example: a product page or landing page).<br><br>ViewContent tells you if someone loads a web page on their browser, but not what they see or do on that page.<br><br>Example: Someone lands on a product details page.<\/td><\/tr><tr><td><strong>VisitCart<\/strong><\/td><td><\/td><td>SmartnewsAds.p(&#8220;your pixel tag ID&#8221;, &#8220;VisitCart&#8221;)<\/td><td>When someone views their shopping cart or basket page<\/td><\/tr><\/tbody><\/table><\/figure>\n\n\n\n<h3 class=\"wp-block-heading\">Standard event parameters<\/h3>\n\n\n\n<p>These parameters are optional, JSON-formatted objects that you can include and associate with standard events. They allow you to track additional information about your website visitors\u2019 actions. Once tracked, parameters can be used to further define any custom audiences you create. For example, when \u201cPurchase\u201d is tracked as a standard event, it\u2019s usually worthwhile to track and send additional parameters such as product IDs, categories, and the number of products purchased, along with the total transaction value.<\/p>\n\n\n\n<p>Parameters supported by SmartNews standard events:<\/p>\n\n\n\n<figure class=\"wp-block-table has-small-font-size\"><table class=\"has-fixed-layout\"><thead><tr><th>Field<\/th><th>Format<\/th><th>Example<\/th><th>Description<\/th><\/tr><\/thead><tbody><tr><td><strong>content_category<\/strong><\/td><td>String<\/td><td>electronics<\/td><td>Category of the page or product<\/td><\/tr><tr><td><strong>content_ids<\/strong><\/td><td>Array of Integers or String<\/td><td>[12345, &#8216;A67890&#8217;]<\/td><td>Product IDs associated with the event, such as SKU numbers<\/td><\/tr><tr><td><strong>content_name<\/strong><\/td><td>String<\/td><td>special product A<\/td><td>Name of the page or product<\/td><\/tr><tr><td><strong>content_type<\/strong><\/td><td>String<\/td><td>product or product_group<\/td><td>Either the <strong>product <\/strong>or <strong>product_group<\/strong> based on the <strong>content_ids<\/strong> or <strong>contents<\/strong> being passed.<br><br>If the IDs being passed in<br><strong>content_ids<\/strong> or contents parameter are IDs of products, then the value should be <strong>product<\/strong>.<br><br>If product group IDs are being passed, then the value should be<br><strong>product_group<\/strong>.<br><br>If no<br><strong>content_type<\/strong> is provided, SmartNews will match the event to every item that has the same ID, independent of its type.<\/td><\/tr><tr><td><strong>contents<\/strong><\/td><td>Array of objects<\/td><td>[{&#8216;id&#8217;: &#8216;ABC123&#8217;, &#8216;quantity&#8217;: 2}, {&#8216;id&#8217;: &#8216;XYZ789&#8217;, &#8216;quantity&#8217;: 2}]<\/td><td>An array of JSON objects that contains the quantity and product or content identifier(s). <strong>id <\/strong>and <strong>quantity<\/strong> are the required fields.<\/td><\/tr><tr><td><strong>currency<\/strong><\/td><td>String<\/td><td>JPY<\/td><td>The currency for the value specified, such as JPY, USD, EUR<\/td><\/tr><tr><td><strong>quantity<\/strong><\/td><td>Integer<\/td><td>2<\/td><td>The number of items when checkout was initiated.<\/td><\/tr><tr><td><strong>predicted_ltv<\/strong><\/td><td>Integer, float<\/td><td>12000.5<\/td><td>Predicted lifetime value of a subscriber as defined by the advertiser and expressed as an exact value.<\/td><\/tr><tr><td><strong>search_string<\/strong><\/td><td>String<\/td><td>wireless earbuds<\/td><td>Used with the Search event. The string entered by the user for the search.<\/td><\/tr><tr><td><strong>status<\/strong><\/td><td>Boolean<\/td><td>true<\/td><td>Used with the <strong>CompleteRegistration<\/strong> event. Returns <strong>true <\/strong>when the user completes full registration, and <strong>false<\/strong> otherwise.<\/td><\/tr><tr><td><strong>value<\/strong><\/td><td>Integer or float<\/td><td>39.99<\/td><td>The monetary value of a user performing this event to the business.<\/td><\/tr><tr><td><strong>time_spent<\/strong><\/td><td>Integer<\/td><td>10000<\/td><td>Time a user spends on the page in milliseconds.<\/td><\/tr><\/tbody><\/table><\/figure>\n\n\n\n<div class=\"wp-block-snow-monkey-blocks-accordion smb-accordion\">\n<div class=\"wp-block-snow-monkey-blocks-accordion-item smb-accordion__item\"><input type=\"checkbox\" class=\"smb-accordion__item__control\" aria-label=\"A accordion item\" \/><div class=\"smb-accordion__item__title\"><span class=\"smb-accordion__item__title__label\">Example<\/span><div class=\"smb-accordion__item__title__icon\"><i class=\"fa-solid fa-angle-down\"><\/i><\/div><\/div><div class=\"smb-accordion__item__body is-layout-constrained wp-block-snow-monkey-blocks-accordion-item-is-layout-constrained\">\n<pre id=\"block-9f3eb7e3-9505-4605-87b2-15fc03dea963\" class=\"wp-block-code\"><code>&lt;!-- SmartNews Ads Pixel Code --&gt;\n&lt;script type=\"text\/javascript\"&gt;\n!function () {\nif (window.SmartnewsAds = window.SmartnewsAds || {}, !window.SmartnewsAds.p) {\nvar e = window.SmartnewsAds.p = function () {\ne.callMethod ? e.callMethod.apply(e, arguments) : e.queue.push(arguments)\n};\nwindow.SmartnewsAds._p || (window.SmartnewsAds._p = e), e.push = e, e.version = \"1.0.0\", e.queue = &#091;];\nvar n = document.createElement(\"script\");\nn.async = !0, n.src = \"https:\/\/cdn.smartnews-ads.com\/i\/pixel.js\";\nvar s = document.getElementsByTagName(\"script\")&#091;0];\ns.parentNode.insertBefore(n, s)\n}\n}();\n\nSmartnewsAds.p(\"&#091;pixel ID]\", \"Purchase\", {\n\"currency\": \"JPY\",\n\"event_value\": 600000,\n\"content_ids\": &#091;400, 401, 402],\n\"content_type\": \"item\"\n});\n&lt;\/script&gt;\n\n\/\/ Choice 1\n&lt;noscript&gt;\n&lt;img height=\"1\" width=\"1\" style=\"display:none;\" alt=\"\" src=\"https:\/\/i.smartnews-ads.com\/p?id=&#091;pixel ID]&amp;e=&#091;event name]\" \/&gt;\n&lt;\/noscript&gt;\n\n\/\/ Choice 2\n\/\/ one \"&amp;d%5B&#091;additional_parameter_key]%5B=&#091;additional_parameter_value]\" will only represents one pair of key value.\n\/\/ example for above will be:\n\/\/ https:\/\/i.smartnews-ads.com\/p?id=&#091;pixel ID]&amp;e=&#091;event name]&amp;d%5Bcurrency%5B=JPY&amp;d%5Bevent_value%5B=600000&amp;d%5Bcontent_ids%5B=400&amp;d%5Bcontent_ids%5B=401&amp;d%5Bcontent_ids%5B=402\n&lt;noscript&gt;\n&lt;img height=\"1\" width=\"1\" style=\"display:none;\" alt=\"\" src=\"https:\/\/i.smartnews-ads.com\/p?id=&#091;pixel ID]&amp;e=&#091;event name]&amp;d%5B&#091;additional_parameter_key]%5B=&#091;additional_parameter_value]\" \/&gt;\n&lt;\/noscript&gt;<\/code><\/pre>\n<\/div><\/div>\n<\/div>\n\n\n\n<h2 class=\"wp-block-heading\">Validating Pixels<\/h2>\n\n\n\n<p>You can test if a Pixel is set up on your website correctly by selecting <strong>Validate Pixel<\/strong> under the Pixels tab. This opens the Pixel validator.<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"269\" src=\"https:\/\/help-ads.smartnews.com\/wp-content\/uploads\/2024\/09\/image-10-1024x269.png\" alt=\"\" class=\"wp-image-4111\" srcset=\"https:\/\/help-ads.smartnews.com\/wp-content\/uploads\/2024\/09\/image-10-1024x269.png 1024w, https:\/\/help-ads.smartnews.com\/wp-content\/uploads\/2024\/09\/image-10-300x79.png 300w, https:\/\/help-ads.smartnews.com\/wp-content\/uploads\/2024\/09\/image-10-768x202.png 768w, https:\/\/help-ads.smartnews.com\/wp-content\/uploads\/2024\/09\/image-10.png 1406w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<p>Enter the web page where your Pixel\u2019s event code is installed and select <strong>Open &amp; validate<\/strong>.<\/p>\n\n\n\n<figure class=\"wp-block-image size-large is-resized\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"919\" src=\"https:\/\/help-ads.smartnews.com\/wp-content\/uploads\/2024\/09\/image-59-1-1024x919.png\" alt=\"\" class=\"wp-image-4113\" style=\"width:842px;height:auto\" srcset=\"https:\/\/help-ads.smartnews.com\/wp-content\/uploads\/2024\/09\/image-59-1-1024x919.png 1024w, https:\/\/help-ads.smartnews.com\/wp-content\/uploads\/2024\/09\/image-59-1-300x269.png 300w, https:\/\/help-ads.smartnews.com\/wp-content\/uploads\/2024\/09\/image-59-1-768x689.png 768w, https:\/\/help-ads.smartnews.com\/wp-content\/uploads\/2024\/09\/image-59-1-1536x1378.png 1536w, https:\/\/help-ads.smartnews.com\/wp-content\/uploads\/2024\/09\/image-59-1-2048x1837.png 2048w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<p>If your base code and event codes are set up correctly, you should see the following message at the top of the validator window:<\/p>\n\n\n\n<figure class=\"wp-block-image size-full is-resized\"><img loading=\"lazy\" decoding=\"async\" width=\"837\" height=\"86\" src=\"https:\/\/help-ads.smartnews.com\/wp-content\/uploads\/2024\/09\/image-60.png\" alt=\"\" class=\"wp-image-4114\" style=\"width:847px;height:auto\" srcset=\"https:\/\/help-ads.smartnews.com\/wp-content\/uploads\/2024\/09\/image-60.png 837w, https:\/\/help-ads.smartnews.com\/wp-content\/uploads\/2024\/09\/image-60-300x31.png 300w, https:\/\/help-ads.smartnews.com\/wp-content\/uploads\/2024\/09\/image-60-768x79.png 768w\" sizes=\"auto, (max-width: 837px) 100vw, 837px\" \/><\/figure>\n\n\n\n<h3 class=\"wp-block-heading\">Validating Pixels on dynamic pages<\/h3>\n\n\n\n<p>When setting up Pixels on dynamic pages like an ASP.NET page, the Pixel validator might mistakenly report that the Pixel hasn&#8217;t fired. For dynamic pages like these, specific user actions may be required that the validator can\u2019t test for using just a URL.<\/p>\n\n\n\n<p>In such cases, you can verify if a Pixel has fired by checking the \u201cLast Event Received\u201d column under the Events tab. If you see events being recorded after an action is completed, your Pixel is implemented correctly.<\/p>\n\n\n\n<p>If you need to use the same event code for multiple URLs, we recommend disabling all the event codes and testing each one individually.<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"259\" src=\"https:\/\/help-ads.smartnews.com\/wp-content\/uploads\/2024\/09\/image-11-1024x259.png\" alt=\"\" class=\"wp-image-4118\" srcset=\"https:\/\/help-ads.smartnews.com\/wp-content\/uploads\/2024\/09\/image-11-1024x259.png 1024w, https:\/\/help-ads.smartnews.com\/wp-content\/uploads\/2024\/09\/image-11-300x76.png 300w, https:\/\/help-ads.smartnews.com\/wp-content\/uploads\/2024\/09\/image-11-768x194.png 768w, https:\/\/help-ads.smartnews.com\/wp-content\/uploads\/2024\/09\/image-11.png 1414w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<p><\/p>\n","protected":false},"excerpt":{"rendered":"Overview SmartNews Pixels are small snippets of code can be added to all of the pages where you wish to track user behavior. You can measure the effectiveness of your conversion funnel and calculate your exact return on investment from SmartNews ads. General workflow for setting up SmartNews Pixels: 1Create a new Pixel from the Events tab in Ads Manager. 2Set up an event which will be used to track the specific behavior we want to track, for example, \u201cAdd to Cart\u201d. 3Add the Pixel\u2019s base code to all the pages where you want to track user behavior. 4Add the event code to the page that will be used to [&hellip;]","protected":false},"author":4,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"inline_featured_image":false,"footnotes":""},"categories":[206],"tags":[],"label":[],"class_list":["post-5510","post","type-post","status-publish","format-standard","hentry","category-tracking-en"],"acf":[],"aioseo_notices":[],"_links":{"self":[{"href":"https:\/\/help-ads.smartnews.com\/en\/wp-json\/wp\/v2\/posts\/5510","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/help-ads.smartnews.com\/en\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/help-ads.smartnews.com\/en\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/help-ads.smartnews.com\/en\/wp-json\/wp\/v2\/users\/4"}],"replies":[{"embeddable":true,"href":"https:\/\/help-ads.smartnews.com\/en\/wp-json\/wp\/v2\/comments?post=5510"}],"version-history":[{"count":8,"href":"https:\/\/help-ads.smartnews.com\/en\/wp-json\/wp\/v2\/posts\/5510\/revisions"}],"predecessor-version":[{"id":7455,"href":"https:\/\/help-ads.smartnews.com\/en\/wp-json\/wp\/v2\/posts\/5510\/revisions\/7455"}],"wp:attachment":[{"href":"https:\/\/help-ads.smartnews.com\/en\/wp-json\/wp\/v2\/media?parent=5510"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/help-ads.smartnews.com\/en\/wp-json\/wp\/v2\/categories?post=5510"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/help-ads.smartnews.com\/en\/wp-json\/wp\/v2\/tags?post=5510"},{"taxonomy":"label","embeddable":true,"href":"https:\/\/help-ads.smartnews.com\/en\/wp-json\/wp\/v2\/label?post=5510"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}