{"id":10618,"date":"2024-11-14T18:03:03","date_gmt":"2024-11-14T18:03:03","guid":{"rendered":"https:\/\/ceowebltd.com\/blog\/?p=10618"},"modified":"2024-11-14T18:03:03","modified_gmt":"2024-11-14T18:03:03","slug":"how-to-set-up-and-track-virtual-pageviews-in-google-tag-manager","status":"publish","type":"post","link":"https:\/\/ceowebltd.com\/blog\/how-to-set-up-and-track-virtual-pageviews-in-google-tag-manager\/","title":{"rendered":"How to set up and track virtual pageviews in Google Tag Manager"},"content":{"rendered":"<p>Tracking virtual pageviews in Google Tag Manager (GTM) is a powerful method to measure non-pageview events that act like traditional pageviews. Virtual pageviews are useful for tracking activities or content viewed on your website that don\u2019t involve loading a new page, such as interactions with dynamic content, single-page applications (SPAs), or tracking events like video plays, form submissions, or custom interactions.<\/p>\n<p>Setting up and tracking virtual pageviews in GTM is straightforward. Below is a step-by-step guide:<\/p>\n<div id=\"ez-toc-container\" class=\"ez-toc-v2_0_73 counter-hierarchy ez-toc-counter ez-toc-grey ez-toc-container-direction\">\n<div class=\"ez-toc-title-container\">\n<p class=\"ez-toc-title\" style=\"cursor:inherit\">Table of Contents<\/p>\n<span class=\"ez-toc-title-toggle\"><a href=\"#\" class=\"ez-toc-pull-right ez-toc-btn ez-toc-btn-xs ez-toc-btn-default ez-toc-toggle\" aria-label=\"Toggle Table of Content\"><span class=\"ez-toc-js-icon-con\"><span class=\"\"><span class=\"eztoc-hide\" style=\"display:none;\">Toggle<\/span><span class=\"ez-toc-icon-toggle-span\"><svg style=\"fill: #999;color:#999\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\" class=\"list-377408\" width=\"20px\" height=\"20px\" viewBox=\"0 0 24 24\" fill=\"none\"><path d=\"M6 6H4v2h2V6zm14 0H8v2h12V6zM4 11h2v2H4v-2zm16 0H8v2h12v-2zM4 16h2v2H4v-2zm16 0H8v2h12v-2z\" fill=\"currentColor\"><\/path><\/svg><svg style=\"fill: #999;color:#999\" class=\"arrow-unsorted-368013\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"10px\" height=\"10px\" viewBox=\"0 0 24 24\" version=\"1.2\" baseProfile=\"tiny\"><path d=\"M18.2 9.3l-6.2-6.3-6.2 6.3c-.2.2-.3.4-.3.7s.1.5.3.7c.2.2.4.3.7.3h11c.3 0 .5-.1.7-.3.2-.2.3-.5.3-.7s-.1-.5-.3-.7zM5.8 14.7l6.2 6.3 6.2-6.3c.2-.2.3-.5.3-.7s-.1-.5-.3-.7c-.2-.2-.4-.3-.7-.3h-11c-.3 0-.5.1-.7.3-.2.2-.3.5-.3.7s.1.5.3.7z\"\/><\/svg><\/span><\/span><\/span><\/a><\/span><\/div>\n<nav><ul class='ez-toc-list ez-toc-list-level-1 ' ><li class='ez-toc-page-1 ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-1\" href=\"https:\/\/ceowebltd.com\/blog\/how-to-set-up-and-track-virtual-pageviews-in-google-tag-manager\/#What_is_a_Virtual_Pageview\" title=\"What is a Virtual Pageview?\">What is a Virtual Pageview?<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-2\" href=\"https:\/\/ceowebltd.com\/blog\/how-to-set-up-and-track-virtual-pageviews-in-google-tag-manager\/#Why_Track_Virtual_Pageviews\" title=\"Why Track Virtual Pageviews?\">Why Track Virtual Pageviews?<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-3\" href=\"https:\/\/ceowebltd.com\/blog\/how-to-set-up-and-track-virtual-pageviews-in-google-tag-manager\/#How_to_Set_Up_Virtual_Pageviews_in_Google_Tag_Manager\" title=\"How to Set Up Virtual Pageviews in Google Tag Manager\">How to Set Up Virtual Pageviews in Google Tag Manager<\/a><ul class='ez-toc-list-level-4' ><li class='ez-toc-heading-level-4'><a class=\"ez-toc-link ez-toc-heading-4\" href=\"https:\/\/ceowebltd.com\/blog\/how-to-set-up-and-track-virtual-pageviews-in-google-tag-manager\/#Step_1_Create_a_Google_Analytics_Pageview_Tag\" title=\"Step 1: Create a Google Analytics Pageview Tag\">Step 1: Create a Google Analytics Pageview Tag<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-4'><a class=\"ez-toc-link ez-toc-heading-5\" href=\"https:\/\/ceowebltd.com\/blog\/how-to-set-up-and-track-virtual-pageviews-in-google-tag-manager\/#Step_2_Create_a_Trigger_for_the_Virtual_Pageview\" title=\"Step 2: Create a Trigger for the Virtual Pageview\">Step 2: Create a Trigger for the Virtual Pageview<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-4'><a class=\"ez-toc-link ez-toc-heading-6\" href=\"https:\/\/ceowebltd.com\/blog\/how-to-set-up-and-track-virtual-pageviews-in-google-tag-manager\/#Step_3_Test_Your_Virtual_Pageview_Tag\" title=\"Step 3: Test Your Virtual Pageview Tag\">Step 3: Test Your Virtual Pageview Tag<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-4'><a class=\"ez-toc-link ez-toc-heading-7\" href=\"https:\/\/ceowebltd.com\/blog\/how-to-set-up-and-track-virtual-pageviews-in-google-tag-manager\/#Step_4_Publish_the_Container\" title=\"Step 4: Publish the Container\">Step 4: Publish the Container<\/a><\/li><\/ul><\/li><li class='ez-toc-page-1 ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-8\" href=\"https:\/\/ceowebltd.com\/blog\/how-to-set-up-and-track-virtual-pageviews-in-google-tag-manager\/#Example_Use_Cases_for_Virtual_Pageviews\" title=\"Example Use Cases for Virtual Pageviews\">Example Use Cases for Virtual Pageviews<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-9\" href=\"https:\/\/ceowebltd.com\/blog\/how-to-set-up-and-track-virtual-pageviews-in-google-tag-manager\/#Conclusion\" title=\"Conclusion\">Conclusion<\/a><\/li><\/ul><\/nav><\/div>\n<h3><span class=\"ez-toc-section\" id=\"What_is_a_Virtual_Pageview\"><\/span>What is a Virtual Pageview?<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<p>A virtual pageview simulates the behavior of a traditional pageview without actually loading a new page. When a user interacts with a specific event or action on your site (such as clicking a button or navigating a specific section of a single-page application), you can send this interaction as a &#8220;pageview&#8221; to Google Analytics, making it easier to measure user engagement on these types of dynamic actions.<\/p>\n<h3><span class=\"ez-toc-section\" id=\"Why_Track_Virtual_Pageviews\"><\/span>Why Track Virtual Pageviews?<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<ul>\n<li><strong>Track Single-Page Applications (SPAs)<\/strong>: For sites that don\u2019t reload the page with each interaction (like SPAs), virtual pageviews let you track \u201cpageviews\u201d for different sections or events.<\/li>\n<li><strong>Track Non-Pageview Actions<\/strong>: For non-pageview interactions (like button clicks, video views, or form submissions), sending virtual pageviews helps measure the content as if it were a new pageview.<\/li>\n<li><strong>Track Specific User Engagement<\/strong>: It allows you to track specific parts of your site that don\u2019t correspond to physical pageviews but are still important for user behavior analysis.<\/li>\n<\/ul>\n<h3><span class=\"ez-toc-section\" id=\"How_to_Set_Up_Virtual_Pageviews_in_Google_Tag_Manager\"><\/span>How to Set Up Virtual Pageviews in Google Tag Manager<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<h4><span class=\"ez-toc-section\" id=\"Step_1_Create_a_Google_Analytics_Pageview_Tag\"><\/span>Step 1: Create a Google Analytics Pageview Tag<span class=\"ez-toc-section-end\"><\/span><\/h4>\n<p>The first step is to create a tag in GTM that will send the virtual pageview data to Google Analytics. Here\u2019s how:<\/p>\n<ol>\n<li><strong>Go to Google Tag Manager<\/strong>:\n<ul>\n<li>Log in to your Google Tag Manager account.<\/li>\n<\/ul>\n<\/li>\n<li><strong>Create a New Tag<\/strong>:\n<ul>\n<li>In the GTM dashboard, go to <strong>Tags<\/strong> and click <strong>New<\/strong>.<\/li>\n<\/ul>\n<\/li>\n<li><strong>Choose Tag Type<\/strong>:\n<ul>\n<li>Select <strong>Google Analytics: Universal Analytics<\/strong> (if you are using Universal Analytics). For Google Analytics 4, you would use the <strong>Google Analytics: GA4 Event<\/strong> tag.<\/li>\n<\/ul>\n<\/li>\n<li><strong>Configure the Tag for Virtual Pageview<\/strong>:\n<ul>\n<li><strong>Tag Configuration<\/strong>: Choose the type of tag, depending on your setup:\n<ul>\n<li>For <strong>Universal Analytics<\/strong>, choose <strong>Pageview<\/strong> as the Track Type.<\/li>\n<li>For <strong>GA4<\/strong>, you will configure an <strong>Event<\/strong> with a custom event name like \u201cvirtual_pageview\u201d.<\/li>\n<\/ul>\n<\/li>\n<li><strong>Google Analytics Settings Variable<\/strong>: If you\u2019ve already set up a Google Analytics Settings variable, select it here. Otherwise, you will need to manually enter your tracking ID (UA-XXXXX-X).<\/li>\n<\/ul>\n<\/li>\n<li><strong>Set the Virtual Page URL<\/strong>:\n<ul>\n<li>This is the key to sending a virtual pageview. In GTM, you can dynamically set the page URL using GTM Variables. Typically, you will want to use a variable that represents the content or the action that you&#8217;re tracking. For example:\n<ul>\n<li>You can create a variable that captures the page or action the user is interacting with (like a specific section ID or a button click).<\/li>\n<li>If you&#8217;re tracking a video view, you might use a variable that dynamically captures the title of the video or the event name.<\/li>\n<\/ul>\n<p>Example for setting the virtual page URL:<\/p>\n<ul>\n<li><strong>Page Path<\/strong>: <code>\/video\/intro-video<\/code> for tracking a video.<\/li>\n<li><strong>Page Title<\/strong>: <code>\u201cVideo Player: Intro Video Played\u201d<\/code> for custom events.<\/li>\n<\/ul>\n<\/li>\n<li>You can set the <strong>Virtual Page URL<\/strong> in the <strong>Page Path<\/strong> field, depending on your tracking requirements.<\/li>\n<li>If you want to track a custom event (e.g., a video play), you can pass the event name as a label or action.<\/li>\n<\/ul>\n<\/li>\n<li><strong>Set Other Fields<\/strong> (Optional):\n<ul>\n<li><strong>Page Title<\/strong>: You can also set the <strong>Page Title<\/strong> as a dynamic variable if required.<\/li>\n<li><strong>Custom Dimensions or Metrics<\/strong>: If you have custom dimensions or metrics in your Google Analytics setup, you can pass them in the fields as well.<\/li>\n<\/ul>\n<\/li>\n<li><strong>Configure Trigger<\/strong>:\n<ul>\n<li>For virtual pageviews, the trigger should be based on an action the user takes. Common triggers include:\n<ul>\n<li><strong>Click Trigger<\/strong>: For clicks on specific buttons or elements (e.g., a play button for a video).<\/li>\n<li><strong>Pageview Trigger<\/strong>: For actions or transitions in a single-page application.<\/li>\n<li><strong>Custom Event Trigger<\/strong>: If you&#8217;re tracking custom JavaScript events.<\/li>\n<li><strong>Form Submission Trigger<\/strong>: To track form submissions.<\/li>\n<\/ul>\n<\/li>\n<\/ul>\n<p>For example, if you are tracking when a user clicks a button to play a video, your trigger could be a <strong>Click Trigger<\/strong> that looks for a button click.<\/li>\n<li><strong>Save the Tag<\/strong>:\n<ul>\n<li>Once configured, give your tag a descriptive name like \u201cVirtual Pageview &#8211; Video Played\u201d and click <strong>Save<\/strong>.<\/li>\n<\/ul>\n<\/li>\n<\/ol>\n<h4><span class=\"ez-toc-section\" id=\"Step_2_Create_a_Trigger_for_the_Virtual_Pageview\"><\/span>Step 2: Create a Trigger for the Virtual Pageview<span class=\"ez-toc-section-end\"><\/span><\/h4>\n<p>Now you need to create a trigger that will fire the virtual pageview tag when a specific action occurs.<\/p>\n<ol>\n<li><strong>Go to Triggers<\/strong>:\n<ul>\n<li>In GTM, go to the <strong>Triggers<\/strong> section and click <strong>New<\/strong>.<\/li>\n<\/ul>\n<\/li>\n<li><strong>Choose the Trigger Type<\/strong>:\n<ul>\n<li>For most cases, you will want to use a <strong>Click Trigger<\/strong> or <strong>Custom Event Trigger<\/strong>, depending on how your website is structured.<\/li>\n<\/ul>\n<p>Example triggers include:<\/p>\n<ul>\n<li><strong>Click \u2013 All Elements<\/strong>: For tracking clicks on specific buttons or links.<\/li>\n<li><strong>Custom Event<\/strong>: If you want to track a custom JavaScript event (such as a video play or user interaction).<\/li>\n<li><strong>History Change Trigger<\/strong>: If you are using a single-page application, this trigger fires when the browser history changes.<\/li>\n<\/ul>\n<\/li>\n<li><strong>Configure the Trigger<\/strong>:\n<ul>\n<li>For a <strong>Click Trigger<\/strong>, specify the conditions such as <strong>Click Element<\/strong> equals <code>#video-play-button<\/code>.<\/li>\n<li>For a <strong>Custom Event Trigger<\/strong>, use the event name that corresponds to your action (e.g., <code>video_played<\/code>).<\/li>\n<\/ul>\n<\/li>\n<li><strong>Save the Trigger<\/strong>.<\/li>\n<\/ol>\n<h4><span class=\"ez-toc-section\" id=\"Step_3_Test_Your_Virtual_Pageview_Tag\"><\/span>Step 3: Test Your Virtual Pageview Tag<span class=\"ez-toc-section-end\"><\/span><\/h4>\n<p>Before you deploy the tag to your live site, you must test it thoroughly.<\/p>\n<ol>\n<li><strong>Use GTM\u2019s Preview Mode<\/strong>:\n<ul>\n<li>Click on <strong>Preview<\/strong> in GTM to enable debugging mode.<\/li>\n<li>Open your website in the same browser and check the GTM preview console.<\/li>\n<\/ul>\n<\/li>\n<li><strong>Test the Trigger<\/strong>:\n<ul>\n<li>Perform the action that should trigger the virtual pageview (e.g., clicking a play button for a video).<\/li>\n<li>Verify that the virtual pageview tag fires correctly in the GTM preview mode and check the <strong>Tags Fired<\/strong> tab.<\/li>\n<\/ul>\n<\/li>\n<li><strong>Check Google Analytics<\/strong>:\n<ul>\n<li>Go to <strong>Real-Time<\/strong> in Google Analytics and verify that the virtual pageview is being recorded.<\/li>\n<li>Check that the <strong>Pageview<\/strong> data or custom events show up with the correct URL or action name.<\/li>\n<\/ul>\n<\/li>\n<\/ol>\n<h4><span class=\"ez-toc-section\" id=\"Step_4_Publish_the_Container\"><\/span>Step 4: Publish the Container<span class=\"ez-toc-section-end\"><\/span><\/h4>\n<p>Once you\u2019ve verified that everything is working correctly:<\/p>\n<ol>\n<li><strong>Go to GTM and click Submit<\/strong> to publish your container.<\/li>\n<li><strong>Go Live<\/strong> with the changes to start tracking virtual pageviews on your live website.<\/li>\n<\/ol>\n<h3><span class=\"ez-toc-section\" id=\"Example_Use_Cases_for_Virtual_Pageviews\"><\/span>Example Use Cases for Virtual Pageviews<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<ol>\n<li><strong>Video Plays<\/strong>:\n<ul>\n<li>Track when users play a video on your site, even though it doesn\u2019t trigger a page reload.<\/li>\n<\/ul>\n<\/li>\n<li><strong>Single-Page Applications<\/strong>:\n<ul>\n<li>In SPAs, virtual pageviews simulate pageviews when users navigate between different views without reloading the page.<\/li>\n<\/ul>\n<\/li>\n<li><strong>Button Clicks and Interactions<\/strong>:\n<ul>\n<li>Track important user interactions, such as clicks on call-to-action buttons, product views, or form submissions.<\/li>\n<\/ul>\n<\/li>\n<li><strong>Download Tracking<\/strong>:\n<ul>\n<li>Track when users download files, such as PDFs, as virtual pageviews to measure engagement.<\/li>\n<\/ul>\n<\/li>\n<\/ol>\n<h3><span class=\"ez-toc-section\" id=\"Conclusion\"><\/span>Conclusion<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<p>Setting up virtual pageviews in Google Tag Manager allows you to track non-pageview interactions as if they were pageviews, making it easier to analyze user behavior on dynamic or interactive websites. By using custom triggers and pageview tags, you can monitor user interactions, such as clicks, video plays, and form submissions, and send this data to Google Analytics. This helps ensure a better understanding of user engagement and allows for data-driven decision-making.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Tracking virtual pageviews in Google Tag Manager (GTM) is a powerful method to measure non-pageview events that act like traditional pageviews. Virtual pageviews are useful&#8230;<\/p>\n","protected":false},"author":214,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[3],"tags":[],"class_list":["post-10618","post","type-post","status-publish","format-standard","hentry","category-digital-marketing"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v22.0 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>How to set up and track virtual pageviews in Google Tag Manager - CEOweb Ltd. Blog<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/ceowebltd.com\/blog\/how-to-set-up-and-track-virtual-pageviews-in-google-tag-manager\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"How to set up and track virtual pageviews in Google Tag Manager - CEOweb Ltd. Blog\" \/>\n<meta property=\"og:description\" content=\"Tracking virtual pageviews in Google Tag Manager (GTM) is a powerful method to measure non-pageview events that act like traditional pageviews. Virtual pageviews are useful...\" \/>\n<meta property=\"og:url\" content=\"https:\/\/ceowebltd.com\/blog\/how-to-set-up-and-track-virtual-pageviews-in-google-tag-manager\/\" \/>\n<meta property=\"og:site_name\" content=\"CEOweb Ltd. Blog\" \/>\n<meta property=\"article:published_time\" content=\"2024-11-14T18:03:03+00:00\" \/>\n<meta name=\"author\" content=\"Emmanuel\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Emmanuel\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"6 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebPage\",\"@id\":\"https:\/\/ceowebltd.com\/blog\/how-to-set-up-and-track-virtual-pageviews-in-google-tag-manager\/\",\"url\":\"https:\/\/ceowebltd.com\/blog\/how-to-set-up-and-track-virtual-pageviews-in-google-tag-manager\/\",\"name\":\"How to set up and track virtual pageviews in Google Tag Manager - CEOweb Ltd. Blog\",\"isPartOf\":{\"@id\":\"https:\/\/ceowebltd.com\/blog\/#website\"},\"datePublished\":\"2024-11-14T18:03:03+00:00\",\"dateModified\":\"2024-11-14T18:03:03+00:00\",\"author\":{\"@id\":\"https:\/\/ceowebltd.com\/blog\/#\/schema\/person\/4759c204c0b0f1d134ec16e8ec777a6f\"},\"breadcrumb\":{\"@id\":\"https:\/\/ceowebltd.com\/blog\/how-to-set-up-and-track-virtual-pageviews-in-google-tag-manager\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/ceowebltd.com\/blog\/how-to-set-up-and-track-virtual-pageviews-in-google-tag-manager\/\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/ceowebltd.com\/blog\/how-to-set-up-and-track-virtual-pageviews-in-google-tag-manager\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/ceowebltd.com\/blog\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"How to set up and track virtual pageviews in Google Tag Manager\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/ceowebltd.com\/blog\/#website\",\"url\":\"https:\/\/ceowebltd.com\/blog\/\",\"name\":\"CEOweb Ltd. Blog\",\"description\":\"Guest Posting - Digital Marketing &amp; Web Services\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/ceowebltd.com\/blog\/?s={search_term_string}\"},\"query-input\":\"required name=search_term_string\"}],\"inLanguage\":\"en-US\"},{\"@type\":\"Person\",\"@id\":\"https:\/\/ceowebltd.com\/blog\/#\/schema\/person\/4759c204c0b0f1d134ec16e8ec777a6f\",\"name\":\"Emmanuel\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/ceowebltd.com\/blog\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/9e883d40261b9b272de51992551b3eec4df631b7579a4fbec69c36a006dcbaf2?s=96&d=mm&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/9e883d40261b9b272de51992551b3eec4df631b7579a4fbec69c36a006dcbaf2?s=96&d=mm&r=g\",\"caption\":\"Emmanuel\"},\"url\":\"https:\/\/ceowebltd.com\/blog\/author\/emmanuel\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"How to set up and track virtual pageviews in Google Tag Manager - CEOweb Ltd. Blog","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/ceowebltd.com\/blog\/how-to-set-up-and-track-virtual-pageviews-in-google-tag-manager\/","og_locale":"en_US","og_type":"article","og_title":"How to set up and track virtual pageviews in Google Tag Manager - CEOweb Ltd. Blog","og_description":"Tracking virtual pageviews in Google Tag Manager (GTM) is a powerful method to measure non-pageview events that act like traditional pageviews. Virtual pageviews are useful...","og_url":"https:\/\/ceowebltd.com\/blog\/how-to-set-up-and-track-virtual-pageviews-in-google-tag-manager\/","og_site_name":"CEOweb Ltd. Blog","article_published_time":"2024-11-14T18:03:03+00:00","author":"Emmanuel","twitter_card":"summary_large_image","twitter_misc":{"Written by":"Emmanuel","Est. reading time":"6 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/ceowebltd.com\/blog\/how-to-set-up-and-track-virtual-pageviews-in-google-tag-manager\/","url":"https:\/\/ceowebltd.com\/blog\/how-to-set-up-and-track-virtual-pageviews-in-google-tag-manager\/","name":"How to set up and track virtual pageviews in Google Tag Manager - CEOweb Ltd. Blog","isPartOf":{"@id":"https:\/\/ceowebltd.com\/blog\/#website"},"datePublished":"2024-11-14T18:03:03+00:00","dateModified":"2024-11-14T18:03:03+00:00","author":{"@id":"https:\/\/ceowebltd.com\/blog\/#\/schema\/person\/4759c204c0b0f1d134ec16e8ec777a6f"},"breadcrumb":{"@id":"https:\/\/ceowebltd.com\/blog\/how-to-set-up-and-track-virtual-pageviews-in-google-tag-manager\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/ceowebltd.com\/blog\/how-to-set-up-and-track-virtual-pageviews-in-google-tag-manager\/"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/ceowebltd.com\/blog\/how-to-set-up-and-track-virtual-pageviews-in-google-tag-manager\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/ceowebltd.com\/blog\/"},{"@type":"ListItem","position":2,"name":"How to set up and track virtual pageviews in Google Tag Manager"}]},{"@type":"WebSite","@id":"https:\/\/ceowebltd.com\/blog\/#website","url":"https:\/\/ceowebltd.com\/blog\/","name":"CEOweb Ltd. Blog","description":"Guest Posting - Digital Marketing &amp; Web Services","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/ceowebltd.com\/blog\/?s={search_term_string}"},"query-input":"required name=search_term_string"}],"inLanguage":"en-US"},{"@type":"Person","@id":"https:\/\/ceowebltd.com\/blog\/#\/schema\/person\/4759c204c0b0f1d134ec16e8ec777a6f","name":"Emmanuel","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/ceowebltd.com\/blog\/#\/schema\/person\/image\/","url":"https:\/\/secure.gravatar.com\/avatar\/9e883d40261b9b272de51992551b3eec4df631b7579a4fbec69c36a006dcbaf2?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/9e883d40261b9b272de51992551b3eec4df631b7579a4fbec69c36a006dcbaf2?s=96&d=mm&r=g","caption":"Emmanuel"},"url":"https:\/\/ceowebltd.com\/blog\/author\/emmanuel\/"}]}},"_links":{"self":[{"href":"https:\/\/ceowebltd.com\/blog\/wp-json\/wp\/v2\/posts\/10618","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/ceowebltd.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/ceowebltd.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/ceowebltd.com\/blog\/wp-json\/wp\/v2\/users\/214"}],"replies":[{"embeddable":true,"href":"https:\/\/ceowebltd.com\/blog\/wp-json\/wp\/v2\/comments?post=10618"}],"version-history":[{"count":1,"href":"https:\/\/ceowebltd.com\/blog\/wp-json\/wp\/v2\/posts\/10618\/revisions"}],"predecessor-version":[{"id":10619,"href":"https:\/\/ceowebltd.com\/blog\/wp-json\/wp\/v2\/posts\/10618\/revisions\/10619"}],"wp:attachment":[{"href":"https:\/\/ceowebltd.com\/blog\/wp-json\/wp\/v2\/media?parent=10618"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/ceowebltd.com\/blog\/wp-json\/wp\/v2\/categories?post=10618"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/ceowebltd.com\/blog\/wp-json\/wp\/v2\/tags?post=10618"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}