{"id":101349,"date":"2025-02-21T11:11:20","date_gmt":"2025-02-21T11:11:20","guid":{"rendered":"https:\/\/peraltafinancing.com\/analytics\/obfuscate-and-duplicate-google-analytics-data\/"},"modified":"2025-02-21T11:11:20","modified_gmt":"2025-02-21T11:11:20","slug":"obfuscate-and-duplicate-google-analytics-data","status":"publish","type":"post","link":"https:\/\/fivemor.com\/?p=101349","title":{"rendered":"Obfuscate And Duplicate Google Analytics Data"},"content":{"rendered":"<p> <br \/>\n<\/p>\n<div>\n<p>Perhaps you didn\u2019t know this, but there\u2019s a really handy <a href=\"https:\/\/support.google.com\/analytics\/answer\/6367342?hl=en\">demo account<\/a> for <a href=\"https:\/\/analytics.google.com\/\">Google Analytics<\/a> you can use to check out how Google Analytics works in a <strong>real<\/strong> business context (the data is from the <a href=\"https:\/\/shop.googlemerchandisestore.com\/\">Google Merchandise Store<\/a>). However, you can access the account with nothing more than <strong>read-only<\/strong> access. This is annoying if you wanted to customize the setup.<\/p>\n<p>Worry not, I have a solution for you! Harnessing the awesome power of <a href=\"https:\/\/www.simoahava.com\/analytics\/customtask-the-guide\/\"><code>customTask<\/code><\/a>, you can create a duplicate of the data collected on <strong>any<\/strong> website where you can modify the tracking (e.g. via <a href=\"https:\/\/tagmanager.google.com\/\">Google Tag Manager<\/a>). Even better, the data will be <strong>obfuscated<\/strong> using a dictionary of English words (you can edit this list), and hashing each string in the payload predictably against this dictionary.<\/p>\n<div style=\"aspect-ratio: 1568 \/ 742;\" class=\"figure nocaption\">\n<p>    <a href=\"https:\/\/www.simoahava.com\/images\/2019\/01\/obfuscated-real-time.jpg\" title=\"Obfuscated real time data view\"><\/p>\n<p>    <img decoding=\"async\" class=\"fig-img\" height=\"742\" width=\"1568\" loading=\"lazy\" src=\"https:\/\/www.simoahava.com\/images\/2019\/01\/obfuscated-real-time.jpg#ZgotmplZ\" alt=\"Obfuscated real time data view\"\/><\/p>\n<p>    <\/a><\/p>\n<\/div>\n<p>As always, you can find this solution in my <a href=\"https:\/\/www.simoahava.com\/tools\/customtask-builder\/\"><strong>customTask Builder tool<\/strong><\/a>.<\/p>\n<div style=\"aspect-ratio: 2208 \/ 796;\" class=\"figure nocaption\">\n<p>    <a href=\"https:\/\/www.simoahava.com\/images\/2019\/01\/customtask-builder.jpg\" title=\"customTask builder\"><\/p>\n<p>    <img decoding=\"async\" class=\"fig-img\" height=\"796\" width=\"2208\" loading=\"lazy\" src=\"https:\/\/www.simoahava.com\/images\/2019\/01\/customtask-builder.jpg#ZgotmplZ\" alt=\"customTask builder\"\/><\/p>\n<p>    <\/a><\/p>\n<\/div>\n<p>Huge thanks to <strong>Jaakko Ojalehto<\/strong>, my illustrious <a href=\"https:\/\/8-bit-sheep.com\">8-bit-sheep<\/a> developer colleague. He came up with the string replacement algorithm.<\/p>\n<p>                <span class=\"simmer\"><br \/>\n  <span class=\"close\">X<\/span><\/p>\n<p>\n    <span class=\"fa fa-md fa-bell\"\/><br \/>\n    <strong>The Simmer Newsletter<\/strong>\n  <\/p>\n<p>\n    Subscribe to the <a href=\"https:\/\/www.simoahava.com\/newsletter\/\">Simmer newsletter<\/a> to get the latest news and content from Simo Ahava into your email inbox!\n  <\/p>\n<p>  <\/span><\/p>\n<h2 id=\"how-to-set-it-up\">How to set it up<\/h2>\n<p>You\u2019ll want to fetch the latest version of the code from the <a href=\"https:\/\/www.simoahava.com\/tools\/customtask-builder\/\">customTask Builder tool<\/a>. See also the instructions for <a href=\"https:\/\/www.simoahava.com\/tools\/customtask-builder\/#general-deployment-instructions\">how to deploy the <code>customTask<\/code><\/a>.<\/p>\n<p>In Google Tag Manager, the <strong>Custom JavaScript variable<\/strong> will end up looking something like this:<\/p>\n<div class=\"highlight\">\n<pre style=\"background-color:#fff;-moz-tab-size:4;-o-tab-size:4;tab-size:4\"><code class=\"language-javascript\" data-lang=\"javascript\"><span style=\"color:#00a\">function<\/span> () {\n  <span style=\"color:#aaa;font-style:italic\">\/\/ customTask Builder by Simo Ahava\n<\/span><span style=\"color:#aaa;font-style:italic\"\/>  <span style=\"color:#aaa;font-style:italic\">\/\/\n<\/span><span style=\"color:#aaa;font-style:italic\"\/>  <span style=\"color:#aaa;font-style:italic\">\/\/ More information about customTask: https:\/\/www.simoahava.com\/analytics\/customtask-the-guide\/\n<\/span><span style=\"color:#aaa;font-style:italic\"\/>  <span style=\"color:#aaa;font-style:italic\">\/\/\n<\/span><span style=\"color:#aaa;font-style:italic\"\/>  <span style=\"color:#aaa;font-style:italic\">\/\/ Change the default values for the settings below.\n<\/span><span style=\"color:#aaa;font-style:italic\"\/>\n  <span style=\"color:#aaa;font-style:italic\">\/\/ obfuscate: Obfuscates the entire hit payload (using a dictionary of words consistently) and dispatches it to the trackingId you provide.\n<\/span><span style=\"color:#aaa;font-style:italic\"\/>  <span style=\"color:#aaa;font-style:italic\">\/\/ https:\/\/bit.ly\/2RectUl\n<\/span><span style=\"color:#aaa;font-style:italic\"\/>  <span style=\"color:#00a\">var<\/span> obfuscate = {\n    tid: <span style=\"color:#a50\">'UA-12345-1'<\/span>,\n    dict: [<span style=\"color:#a50\">'tumble'<\/span>, <span style=\"color:#a50\">'noble'<\/span>, <span style=\"color:#a50\">'flourish'<\/span>, <span style=\"color:#a50\">'abandon'<\/span>, <span style=\"color:#a50\">'liberal'<\/span>, <span style=\"color:#a50\">'team'<\/span>, <span style=\"color:#a50\">'conflict'<\/span>, <span style=\"color:#a50\">'collar'<\/span>, <span style=\"color:#a50\">'tiger'<\/span>, <span style=\"color:#a50\">'stun'<\/span>, <span style=\"color:#a50\">'grace'<\/span>, <span style=\"color:#a50\">'resource'<\/span>, <span style=\"color:#a50\">'phantom'<\/span>, <span style=\"color:#a50\">'imagine'<\/span>, <span style=\"color:#a50\">'information'<\/span>, <span style=\"color:#a50\">'hall'<\/span>, <span style=\"color:#a50\">'sweet'<\/span>, <span style=\"color:#a50\">'agriculture'<\/span>, <span style=\"color:#a50\">'bingo'<\/span>, <span style=\"color:#a50\">'relative'<\/span>],\n    stringParams: [<span style=\"color:#a50\">'uid'<\/span>,<span style=\"color:#a50\">'ua'<\/span>,<span style=\"color:#a50\">'dr'<\/span>,<span style=\"color:#a50\">'cn'<\/span>,<span style=\"color:#a50\">'cs'<\/span>,<span style=\"color:#a50\">'cm'<\/span>,<span style=\"color:#a50\">'ck'<\/span>,<span style=\"color:#a50\">'cc'<\/span>,<span style=\"color:#a50\">'ci'<\/span>,<span style=\"color:#a50\">'gclid'<\/span>,<span style=\"color:#a50\">'dclid'<\/span>,<span style=\"color:#a50\">'dl'<\/span>,<span style=\"color:#a50\">'dh'<\/span>,<span style=\"color:#a50\">'dp'<\/span>,<span style=\"color:#a50\">'dt'<\/span>,<span style=\"color:#a50\">'cd'<\/span>,<span style=\"color:#a50\">'cg[1-5]'<\/span>,<span style=\"color:#a50\">'linkid'<\/span>,<span style=\"color:#a50\">'an'<\/span>,<span style=\"color:#a50\">'aid'<\/span>,<span style=\"color:#a50\">'av'<\/span>,<span style=\"color:#a50\">'aiid'<\/span>,<span style=\"color:#a50\">'ec'<\/span>,<span style=\"color:#a50\">'ea'<\/span>,<span style=\"color:#a50\">'el'<\/span>,<span style=\"color:#a50\">'ti'<\/span>,<span style=\"color:#a50\">'ta'<\/span>,<span style=\"color:#a50\">'in'<\/span>,<span style=\"color:#a50\">'ic'<\/span>,<span style=\"color:#a50\">'iv'<\/span>,<span style=\"color:#a50\">'pr\\\\d{1,3}id'<\/span>,<span style=\"color:#a50\">'pr\\\\d{1,3}nm'<\/span>,<span style=\"color:#a50\">'pr\\\\d{1,3}br'<\/span>,<span style=\"color:#a50\">'pr\\\\d{1,3}ca'<\/span>,<span style=\"color:#a50\">'pr\\\\d{1,3}va'<\/span>,<span style=\"color:#a50\">'pr\\\\d{1,3}cc'<\/span>,<span style=\"color:#a50\">'pr\\\\d{1,3}cd\\\\d{1,3}'<\/span>,<span style=\"color:#a50\">'tcc'<\/span>,<span style=\"color:#a50\">'pal'<\/span>,<span style=\"color:#a50\">'col'<\/span>,<span style=\"color:#a50\">'il\\\\d{1,3}nm'<\/span>,<span style=\"color:#a50\">'il\\\\d{1,3}pi\\\\d{1,3}id'<\/span>,<span style=\"color:#a50\">'il\\\\d{1,3}pi\\\\d{1,3}nm'<\/span>,<span style=\"color:#a50\">'il\\\\d{1,3}pi\\\\d{1,3}br'<\/span>,<span style=\"color:#a50\">'il\\\\d{1,3}pi\\\\d{1,3}ca'<\/span>,<span style=\"color:#a50\">'il\\\\d{1,3}pi\\\\d{1,3}va'<\/span>,<span style=\"color:#a50\">'il\\\\d{1,3}pi\\\\d{1,3}cd\\\\d{1,3}'<\/span>,<span style=\"color:#a50\">'promo\\\\d{1,3}id'<\/span>,<span style=\"color:#a50\">'promo\\\\d{1,3}nm'<\/span>,<span style=\"color:#a50\">'promo\\\\d{1,3}cr'<\/span>,<span style=\"color:#a50\">'promo\\\\d{1,3}ps'<\/span>,<span style=\"color:#a50\">'sn'<\/span>,<span style=\"color:#a50\">'sa'<\/span>,<span style=\"color:#a50\">'st'<\/span>,<span style=\"color:#a50\">'utc'<\/span>,<span style=\"color:#a50\">'utv'<\/span>,<span style=\"color:#a50\">'utl'<\/span>,<span style=\"color:#a50\">'exd'<\/span>,<span style=\"color:#a50\">'cd\\\\d{1,3}'<\/span>,<span style=\"color:#a50\">'xid'<\/span>,<span style=\"color:#a50\">'exp'<\/span>,<span style=\"color:#a50\">'_utmz'<\/span>],\n    priceParams: [<span style=\"color:#a50\">'tr'<\/span>,<span style=\"color:#a50\">'ts'<\/span>,<span style=\"color:#a50\">'tt'<\/span>,<span style=\"color:#a50\">'ip'<\/span>,<span style=\"color:#a50\">'pr\\\\d{1,3}pr'<\/span>,<span style=\"color:#a50\">'id\\\\d{1,3}pi\\\\d{1,3}pr'<\/span>],\n    priceModifier: <span style=\"color:#0aa\">Math<\/span>.random(),\n    medium: [<span style=\"color:#a50\">'organic'<\/span>, <span style=\"color:#a50\">'referral'<\/span>, <span style=\"color:#a50\">'social'<\/span>, <span style=\"color:#a50\">'cpc'<\/span>],\n    replaceString: <span style=\"color:#00a\">function<\/span>(t){<span style=\"color:#00a\">if<\/span>(<span style=\"color:#a50\">''<\/span>===t)<span style=\"color:#00a\">return<\/span> t;<span style=\"color:#a50\">'function'<\/span>==<span style=\"color:#00a\">typeof<\/span> <span style=\"color:#0aa\">window<\/span>.btoa&amp;&amp;(t=btoa(t));<span style=\"color:#00a\">var<\/span> n=t.split(<span style=\"color:#a50\">''<\/span>).map(<span style=\"color:#00a\">function<\/span>(t){<span style=\"color:#00a\">return<\/span> t.charCodeAt(<span style=\"color:#099\">0<\/span>)}).join(<span style=\"color:#a50\">''<\/span>)%obfuscate.dict.length;<span style=\"color:#00a\">return<\/span> obfuscate.dict[n]},\n    init: <span style=\"color:#00a\">function<\/span>(){<span style=\"color:#00a\">var<\/span> c=[];obfuscate.dict.forEach(<span style=\"color:#00a\">function<\/span>(t){obfuscate.dict.forEach(<span style=\"color:#00a\">function<\/span>(o){c.push(t+<span style=\"color:#a50\">'-'<\/span>+o)})}),obfuscate.dict=obfuscate.dict.concat(c)}\n  };\n\n  <span style=\"color:#aaa;font-style:italic\">\/\/ DO NOT EDIT ANYTHING BELOW THIS LINE\n<\/span><span style=\"color:#aaa;font-style:italic\"\/>  <span style=\"color:#00a\">if<\/span> (<span style=\"color:#00a\">typeof<\/span> obfuscate === <span style=\"color:#a50\">'object'<\/span> &amp;&amp; <span style=\"color:#00a\">typeof<\/span> obfuscate.init === <span style=\"color:#a50\">'function'<\/span>) obfuscate.init();\n\n  <span style=\"color:#00a\">var<\/span> readFromStorage = <span style=\"color:#00a\">function<\/span> (key) {\n    <span style=\"color:#00a\">if<\/span> (!<span style=\"color:#0aa\">window<\/span>.Storage) {\n      <span style=\"color:#aaa;font-style:italic\">\/\/ From: https:\/\/stackoverflow.com\/a\/15724300\/2367037\n<\/span><span style=\"color:#aaa;font-style:italic\"\/>      <span style=\"color:#00a\">var<\/span> value = <span style=\"color:#a50\">'; '<\/span> + <span style=\"color:#0aa\">document<\/span>.cookie;\n      <span style=\"color:#00a\">var<\/span> parts = value.split(<span style=\"color:#a50\">'; '<\/span> + key + <span style=\"color:#a50\">'='<\/span>);\n      <span style=\"color:#00a\">if<\/span> (parts.length === <span style=\"color:#099\">2<\/span>) {\n        <span style=\"color:#00a\">return<\/span> parts.pop().split(<span style=\"color:#a50\">';'<\/span>).shift();\n      }\n    } <span style=\"color:#00a\">else<\/span> {\n      <span style=\"color:#00a\">return<\/span> <span style=\"color:#0aa\">window<\/span>.localStorage.getItem(key);\n    }\n  };\n\n  <span style=\"color:#00a\">var<\/span> writeToStorage = <span style=\"color:#00a\">function<\/span> (key, value, expireDays) {\n    <span style=\"color:#00a\">if<\/span> (!<span style=\"color:#0aa\">window<\/span>.Storage) {\n      <span style=\"color:#00a\">var<\/span> expiresDate = <span style=\"color:#00a\">new<\/span> <span style=\"color:#0aa\">Date<\/span>();\n      expiresDate.setDate(expiresDate.getDate() + expireDays);\n      <span style=\"color:#0aa\">document<\/span>.cookie = key + <span style=\"color:#a50\">'='<\/span> + value + <span style=\"color:#a50\">';expires='<\/span> + expiresDate.toUTCString();\n    } <span style=\"color:#00a\">else<\/span> {\n      <span style=\"color:#0aa\">window<\/span>.localStorage.setItem(key, value);\n    }\n  };\n\n  <span style=\"color:#00a\">var<\/span> globalSendHitTaskName   = <span style=\"color:#a50\">'_ga_originalSendHitTask'<\/span>;\n\n  <span style=\"color:#00a\">return<\/span> <span style=\"color:#00a\">function<\/span> (customTaskModel) {\n\n    <span style=\"color:#0aa\">window<\/span>[globalSendHitTaskName] = <span style=\"color:#0aa\">window<\/span>[globalSendHitTaskName] || customTaskModel.get(<span style=\"color:#a50\">'sendHitTask'<\/span>);\n\n    customTaskModel.set(<span style=\"color:#a50\">'sendHitTask'<\/span>, <span style=\"color:#00a\">function<\/span> (sendHitTaskModel) {\n\n      <span style=\"color:#00a\">var<\/span> originalSendHitTaskModel = sendHitTaskModel,\n          originalSendHitTask      = <span style=\"color:#0aa\">window<\/span>[globalSendHitTaskName],\n          canSendHit               = <span style=\"color:#00a\">true<\/span>;\n\n      <span style=\"color:#00a\">try<\/span> {\n\n        <span style=\"color:#00a\">if<\/span> (canSendHit) {\n          originalSendHitTask(sendHitTaskModel);\n        }\n\n        <span style=\"color:#aaa;font-style:italic\">\/\/ obfuscate\n<\/span><span style=\"color:#aaa;font-style:italic\"\/>        <span style=\"color:#00a\">if<\/span> (<span style=\"color:#00a\">typeof<\/span> obfuscate === <span style=\"color:#a50\">'object'<\/span> &amp;&amp; obfuscate.hasOwnProperty(<span style=\"color:#a50\">'tid'<\/span>) &amp;&amp; obfuscate.hasOwnProperty(<span style=\"color:#a50\">'dict'<\/span>) &amp;&amp; obfuscate.hasOwnProperty(<span style=\"color:#a50\">'stringParams'<\/span>) &amp;&amp; obfuscate.hasOwnProperty(<span style=\"color:#a50\">'priceParams'<\/span>) &amp;&amp; obfuscate.hasOwnProperty(<span style=\"color:#a50\">'replaceString'<\/span>) &amp;&amp; obfuscate.hasOwnProperty(<span style=\"color:#a50\">'priceModifier'<\/span>)) {\n          <span style=\"color:#00a\">var<\/span> _o_hitPayload = sendHitTaskModel.get(<span style=\"color:#a50\">'hitPayload'<\/span>);\n          obfuscate.stringParams.forEach(<span style=\"color:#00a\">function<\/span>(strParam) {\n            <span style=\"color:#00a\">var<\/span> regexParam = <span style=\"color:#00a\">new<\/span> <span style=\"color:#0aa\">RegExp<\/span>(<span style=\"color:#a50\">'[?&amp;]'<\/span> + strParam + <span style=\"color:#a50\">'=[^&amp;]+'<\/span>, <span style=\"color:#a50\">'g'<\/span>);\n            <span style=\"color:#00a\">var<\/span> paramsInHitpayload = _o_hitPayload.match(regexParam) || [];\n            paramsInHitpayload.forEach(<span style=\"color:#00a\">function<\/span>(keyValue) {\n              <span style=\"color:#00a\">var<\/span> parts = keyValue.split(<span style=\"color:#a50\">'='<\/span>);\n              <span style=\"color:#00a\">var<\/span> urlParts = parts[<span style=\"color:#099\">1<\/span>].split(<span style=\"color:#a50\">'%2F'<\/span>).map(<span style=\"color:#00a\">function<\/span>(urlPart) {\n                <span style=\"color:#00a\">if<\/span> (<span style=\"color:#099\">\/https?:\/<\/span>.test(<span style=\"color:#0aa\">decodeURIComponent<\/span>(urlPart))) <span style=\"color:#00a\">return<\/span> urlPart;\n                <span style=\"color:#00a\">return<\/span> urlPart.split(<span style=\"color:#a50\">'%20'<\/span>).map(<span style=\"color:#00a\">function<\/span>(wordPart) {\n                  <span style=\"color:#00a\">return<\/span> obfuscate.replaceString(wordPart);\n                }).join(<span style=\"color:#a50\">'%20'<\/span>);\n              }).join(<span style=\"color:#a50\">'%2F'<\/span>);\n              _o_hitPayload = _o_hitPayload.replace(parts.join(<span style=\"color:#a50\">'='<\/span>), parts[<span style=\"color:#099\">0<\/span>] + <span style=\"color:#a50\">'='<\/span> + urlParts);\n            });\n          });\n          obfuscate.priceParams.forEach(<span style=\"color:#00a\">function<\/span>(prParam) {\n            <span style=\"color:#00a\">var<\/span> regexParam = <span style=\"color:#00a\">new<\/span> <span style=\"color:#0aa\">RegExp<\/span>(<span style=\"color:#a50\">'[?&amp;]'<\/span> + prParam + <span style=\"color:#a50\">'=[^&amp;]+'<\/span>, <span style=\"color:#a50\">'g'<\/span>);\n            <span style=\"color:#00a\">var<\/span> paramsInHitpayload = _o_hitPayload.match(regexParam) || [];\n            paramsInHitpayload.forEach(<span style=\"color:#00a\">function<\/span>(keyValue) {\n              <span style=\"color:#00a\">var<\/span> parts = keyValue.split(<span style=\"color:#a50\">'='<\/span>);\n              <span style=\"color:#00a\">var<\/span> price = <span style=\"color:#0aa\">parseFloat<\/span>(parts[<span style=\"color:#099\">1<\/span>]) || <span style=\"color:#099\">0.00<\/span>;\n              price = (price * obfuscate.priceModifier).toFixed(<span style=\"color:#099\">2<\/span>);\n              _o_hitPayload = _o_hitPayload.replace(parts.join(<span style=\"color:#a50\">'='<\/span>), parts[<span style=\"color:#099\">0<\/span>] + <span style=\"color:#a50\">'='<\/span> + price);\n            });\n          });\n          _o_hitPayload = _o_hitPayload\n            .replace(\n              <span style=\"color:#a50\">'&amp;tid='<\/span> + sendHitTaskModel.get(<span style=\"color:#a50\">'trackingId'<\/span>) + <span style=\"color:#a50\">'&amp;'<\/span>, \n              <span style=\"color:#a50\">'&amp;tid='<\/span> + obfuscate.tid + <span style=\"color:#a50\">'&amp;'<\/span>\n            )\n            .replace(<span style=\"color:#099\">\/[?&amp;]aip($|&amp;|=[^&amp;]*)\/<\/span>, <span style=\"color:#a50\">''<\/span>)\n            .replace(<span style=\"color:#099\">\/[?&amp;]c[sm]=[^&amp;]*\/g<\/span>, <span style=\"color:#a50\">''<\/span>)\n            .replace(<span style=\"color:#099\">\/[?&amp;]uip=[^&amp;]*\/g<\/span>, <span style=\"color:#a50\">''<\/span>);\n          <span style=\"color:#00a\">if<\/span> (<span style=\"color:#0aa\">Math<\/span>.random() 0.10) {\n            _o_hitPayload += \n              <span style=\"color:#a50\">'&amp;cs='<\/span> + obfuscate.dict[<span style=\"color:#0aa\">Math<\/span>.floor(<span style=\"color:#0aa\">Math<\/span>.random()*obfuscate.dict.length)] + \n              <span style=\"color:#a50\">'&amp;cm='<\/span> + obfuscate.medium[<span style=\"color:#0aa\">Math<\/span>.floor(<span style=\"color:#0aa\">Math<\/span>.random()*obfuscate.medium.length)];\n          }\n          _o_hitPayload += <span style=\"color:#a50\">'&amp;uip='<\/span> + \n            (<span style=\"color:#0aa\">Math<\/span>.floor(<span style=\"color:#0aa\">Math<\/span>.random() * <span style=\"color:#099\">255<\/span>) + <span style=\"color:#099\">1<\/span>) + <span style=\"color:#a50\">'.'<\/span> +\n            (<span style=\"color:#0aa\">Math<\/span>.floor(<span style=\"color:#0aa\">Math<\/span>.random() * <span style=\"color:#099\">255<\/span>) + <span style=\"color:#099\">0<\/span>) + <span style=\"color:#a50\">'.'<\/span> +\n            (<span style=\"color:#0aa\">Math<\/span>.floor(<span style=\"color:#0aa\">Math<\/span>.random() * <span style=\"color:#099\">255<\/span>) + <span style=\"color:#099\">0<\/span>) + <span style=\"color:#a50\">'.'<\/span> +\n            (<span style=\"color:#0aa\">Math<\/span>.floor(<span style=\"color:#0aa\">Math<\/span>.random() * <span style=\"color:#099\">255<\/span>) + <span style=\"color:#099\">0<\/span>);\n          _o_hitPayload += <span style=\"color:#a50\">'&amp;aip=1'<\/span>;\n          sendHitTaskModel.set(<span style=\"color:#a50\">'hitPayload'<\/span>, _o_hitPayload, <span style=\"color:#00a\">true<\/span>);\n          originalSendHitTask(sendHitTaskModel);\n        }\n        <span style=\"color:#aaa;font-style:italic\">\/\/ \/obfuscate\n<\/span><span style=\"color:#aaa;font-style:italic\"\/>\n      } <span style=\"color:#00a\">catch<\/span>(err) {\n        originalSendHitTask(originalSendHitTaskModel);\n      }\n\n    });\n\n  };\n}\n<\/code><\/pre>\n<\/div>\n<p>That\u2019s quite a bit of code, because it turns out that obfuscating the data consistently and taking care of all the other possible pitfalls with duplicating Google Analytics data isn\u2019t exactly trivial.<\/p>\n<p>Anyway, to set the thing up, you\u2019ll need to edit the configuration object within the <code>var obfuscate = {...}<\/code> block. Here are the configuration keys and how to use them. <strong>Note!<\/strong> All the keys are required for the solution to work. If you remove one of the keys, obfuscation will be aborted.<\/p>\n<table>\n<thead>\n<tr>\n<th>Key<\/th>\n<th>Initial value<\/th>\n<th>Description<\/th>\n<\/tr>\n<\/thead>\n<tbody>\n<tr>\n<td><code>trackingId<\/code><\/td>\n<td><code>UA-12345-1<\/code><\/td>\n<td>The Tracking ID to which you want the data to be dispatched. Only one tracking ID is supported at this time.<\/td>\n<\/tr>\n<tr>\n<td><code>dict<\/code><\/td>\n<td><code>['tumble', 'noble'...]<\/code><\/td>\n<td>The dictionary of words that will be used. Don\u2019t add too many (20 should suffice). When the function is initialized, it will automatically generate compound words from every item in the dictionary.<\/td>\n<\/tr>\n<tr>\n<td><code>stringParams<\/code><\/td>\n<td><code>['uid','ua'...]<\/code><\/td>\n<td>All the <a href=\"https:\/\/developers.google.com\/analytics\/devguides\/collection\/protocol\/v1\/parameters\">Measurement Protocol parameters<\/a> that will be treated as strings and will be replaced with words in the dictionary. The parameter names are regular expression patterns.<\/td>\n<\/tr>\n<tr>\n<td><code>priceParams<\/code><\/td>\n<td><code>['tr','ts'...]<\/code><\/td>\n<td>All the Measurement Protocol parameters that will be treated as prices and will be modified with the <code>priceModifier<\/code> value (see below). The parameter names are regular expression patterns.<\/td>\n<\/tr>\n<tr>\n<td><code>priceModifier<\/code><\/td>\n<td><code>Math.random()<\/code><\/td>\n<td>The modifier which will be used to modify all prices in the payload. The initial value (<code>Math.random()<\/code>) basically means that prices will be modified with a random percentage between 0.00 and 1.00.<\/td>\n<\/tr>\n<tr>\n<td><code>medium<\/code><\/td>\n<td><code>['organic', 'referral'...]<\/code><\/td>\n<td>The list of campaign media that will be randomly assigned to 10% of hits (to get some source\/medium variance).<\/td>\n<\/tr>\n<tr>\n<td><code>replaceString<\/code><\/td>\n<td><code>function<\/code><\/td>\n<td>Internal function, <strong>do not modify<\/strong>.<\/td>\n<\/tr>\n<tr>\n<td><code>init<\/code><\/td>\n<td><code>function<\/code><\/td>\n<td>Internal function, <strong>do not modify<\/strong>.<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p>You\u2019ll want to edit <code>trackingId<\/code> at the very least. the other configurations have completely functional default values, so there\u2019s no need to touch them unless you want to. For example, you might want to rewrite the <code>dict<\/code> to include words that actually have to do with some real industry.<\/p>\n<p>To get most out of your data, you\u2019ll want to add this <code>customTask<\/code> to all the hits dispatched to a Google Analytics property from your website. That way you\u2019ll get the most comprehensive and realistic data set.<\/p>\n<h2 id=\"how-it-works\">How it works<\/h2>\n<p>The obfuscation itself is fairly complex.<\/p>\n<p>First, when tag is first run, the obfuscator is <strong>initialized<\/strong>. This initialization basically takes your dictionary of words, and generates a compound of every word against every other word in the dictionary. Thus the final length of the dictionary is <code>n + n^2<\/code> squared, where <code>n<\/code> is the initial length of the dictionary. For example, if this is your initial dictionary:<\/p>\n<p><code>['baby', 'rock', 'sweet']<\/code><\/p>\n<p>The final dictionary will be:<\/p>\n<p><code>['baby', 'rock', 'sweet', 'baby-baby', baby-rock', 'baby-sweet', 'rock-baby', 'rock-rock', 'rock-sweet', 'sweet-baby', 'sweet-rock', 'sweet-sweet']<\/code><\/p>\n<p>The obfuscation itself is a multi-step process.<\/p>\n<ol>\n<li><strong>First<\/strong>, all string parameters from the configuration are looped through. If a match is made in the payload, then the value of the string parameter is first turned into a <strong>Base64<\/strong> representation, and then a simple algorithm is used to turn this encoded string into a number, which is then compressed into an index number of the dictionary.<\/li>\n<\/ol>\n<div class=\"highlight\">\n<pre style=\"background-color:#fff;-moz-tab-size:4;-o-tab-size:4;tab-size:4\"><code class=\"language-javascript\" data-lang=\"javascript\">obfuscate.stringParams.forEach(<span style=\"color:#00a\">function<\/span>(strParam) {\n  <span style=\"color:#00a\">var<\/span> regexParam = <span style=\"color:#00a\">new<\/span> <span style=\"color:#0aa\">RegExp<\/span>(<span style=\"color:#a50\">'[?&amp;]'<\/span> + strParam + <span style=\"color:#a50\">'=[^&amp;]+'<\/span>, <span style=\"color:#a50\">'g'<\/span>);\n  <span style=\"color:#00a\">var<\/span> paramsInHitpayload = _o_hitPayload.match(regexParam) || [];\n  paramsInHitpayload.forEach(<span style=\"color:#00a\">function<\/span>(keyValue) {\n    <span style=\"color:#00a\">var<\/span> parts = keyValue.split(<span style=\"color:#a50\">'='<\/span>);\n    <span style=\"color:#00a\">var<\/span> urlParts = parts[<span style=\"color:#099\">1<\/span>].split(<span style=\"color:#a50\">'%2F'<\/span>).map(<span style=\"color:#00a\">function<\/span>(urlPart) {\n      <span style=\"color:#00a\">if<\/span> (<span style=\"color:#099\">\/https?:\/<\/span>.test(<span style=\"color:#0aa\">decodeURIComponent<\/span>(urlPart))) <span style=\"color:#00a\">return<\/span> urlPart;\n      <span style=\"color:#00a\">return<\/span> urlPart.split(<span style=\"color:#a50\">'%20'<\/span>).map(<span style=\"color:#00a\">function<\/span>(wordPart) {\n        <span style=\"color:#00a\">return<\/span> obfuscate.replaceString(wordPart);\n      }).join(<span style=\"color:#a50\">'%20'<\/span>);\n    }).join(<span style=\"color:#a50\">'%2F'<\/span>);\n    _o_hitPayload = _o_hitPayload.replace(parts.join(<span style=\"color:#a50\">'='<\/span>), parts[<span style=\"color:#099\">0<\/span>] + <span style=\"color:#a50\">'='<\/span> + urlParts);\n  });\n});\n<\/code><\/pre>\n<\/div>\n<p>This means that every single string will have a consistent counterpart in the dictionary. Some strings will naturally return the same dictionary word, but that\u2019s ok since we\u2019re not going for perfect traceability here, and this will also make it even more difficult to reverse-engineer the translated strings back to their original representations.<\/p>\n<p>If the string is found to have a <code>\/<\/code> symbol, then each word separated by the slash will be translated separately. This way URLs will be kept intact. In a similar vein, if the string has <code>http:<\/code> or <code>https:<\/code>, then the protocol will <strong>not<\/strong> be translated, because GA requires valid URLs in certain parameters.<\/p>\n<p>Finally, if the strings are comprised of words (separated by whitespace), then each word is translated separately.<\/p>\n<ol start=\"2\">\n<li><strong>Next<\/strong>, the price parameters are matched in a similar way against the hit payload. If a match is made, then the price is modified by the <code>priceModifier<\/code> from the configuration. Each price using this tracker is modified with the same modifier.<\/li>\n<\/ol>\n<div class=\"highlight\">\n<pre style=\"background-color:#fff;-moz-tab-size:4;-o-tab-size:4;tab-size:4\"><code class=\"language-javascript\" data-lang=\"javascript\">obfuscate.priceParams.forEach(<span style=\"color:#00a\">function<\/span>(prParam) {\n  <span style=\"color:#00a\">var<\/span> regexParam = <span style=\"color:#00a\">new<\/span> <span style=\"color:#0aa\">RegExp<\/span>(<span style=\"color:#a50\">'[?&amp;]'<\/span> + prParam + <span style=\"color:#a50\">'=[^&amp;]+'<\/span>, <span style=\"color:#a50\">'g'<\/span>);\n  <span style=\"color:#00a\">var<\/span> paramsInHitpayload = _o_hitPayload.match(regexParam) || [];\n  paramsInHitpayload.forEach(<span style=\"color:#00a\">function<\/span>(keyValue) {\n    <span style=\"color:#00a\">var<\/span> parts = keyValue.split(<span style=\"color:#a50\">'='<\/span>);\n    <span style=\"color:#00a\">var<\/span> price = <span style=\"color:#0aa\">parseFloat<\/span>(parts[<span style=\"color:#099\">1<\/span>]) || <span style=\"color:#099\">0.00<\/span>;\n    price = (price * obfuscate.priceModifier).toFixed(<span style=\"color:#099\">2<\/span>);\n    _o_hitPayload = _o_hitPayload.replace(parts.join(<span style=\"color:#a50\">'='<\/span>), parts[<span style=\"color:#099\">0<\/span>] + <span style=\"color:#a50\">'='<\/span> + price);\n  });\n});\n<\/code><\/pre>\n<\/div>\n<ol start=\"3\">\n<li><strong>Then<\/strong>, the tracking ID in the payload is replaced by the one you provide in the configuration object. At the same time, the parameters <code>aip<\/code>, <code>cs<\/code>, <code>cm<\/code>, and <code>uip<\/code> (for Anonymize IP, Campaign Source, Campaign Medium, and Override IP, respectively) are removed from the payload.<\/li>\n<\/ol>\n<div class=\"highlight\">\n<pre style=\"background-color:#fff;-moz-tab-size:4;-o-tab-size:4;tab-size:4\"><code class=\"language-javascript\" data-lang=\"javascript\">_o_hitPayload = _o_hitPayload\n  .replace(\n    <span style=\"color:#a50\">'&amp;tid='<\/span> + sendHitTaskModel.get(<span style=\"color:#a50\">'trackingId'<\/span>) + <span style=\"color:#a50\">'&amp;'<\/span>, \n    <span style=\"color:#a50\">'&amp;tid='<\/span> + obfuscate.tid + <span style=\"color:#a50\">'&amp;'<\/span>\n  )\n  .replace(<span style=\"color:#099\">\/[?&amp;]aip($|&amp;|=[^&amp;]*)\/<\/span>, <span style=\"color:#a50\">''<\/span>)\n  .replace(<span style=\"color:#099\">\/[?&amp;]c[sm]=[^&amp;]*\/g<\/span>, <span style=\"color:#a50\">''<\/span>)\n  .replace(<span style=\"color:#099\">\/[?&amp;]uip=[^&amp;]*\/g<\/span>, <span style=\"color:#a50\">''<\/span>);\n<\/code><\/pre>\n<\/div>\n<ol start=\"4\">\n<li><strong>Finally<\/strong>, 10% of all hits are assigned a random campaign source (from the dictionary), with a random medium from the list of <code>medium<\/code> you provided in the configuration.<\/li>\n<\/ol>\n<div style=\"aspect-ratio: 1658 \/ 760;\" class=\"figure nocaption\">\n<p>    <a href=\"https:\/\/www.simoahava.com\/images\/2019\/01\/data-example.jpg\" title=\"Example data\"><\/p>\n<p>    <img decoding=\"async\" class=\"fig-img\" height=\"760\" width=\"1658\" loading=\"lazy\" src=\"https:\/\/www.simoahava.com\/images\/2019\/01\/data-example.jpg#ZgotmplZ\" alt=\"Example data\"\/><\/p>\n<p>    <\/a><\/p>\n<\/div>\n<p>Also, a random IP address is generated for the hit. Yes, every hit.<\/p>\n<p>Then, the IP address is anonymized with the Anonymize IP parameter.<\/p>\n<div class=\"highlight\">\n<pre style=\"background-color:#fff;-moz-tab-size:4;-o-tab-size:4;tab-size:4\"><code class=\"language-javascript\" data-lang=\"javascript\"><span style=\"color:#00a\">if<\/span> (<span style=\"color:#0aa\">Math<\/span>.random() 0.10) {\n  _o_hitPayload += \n    <span style=\"color:#a50\">'&amp;cs='<\/span> + obfuscate.dict[<span style=\"color:#0aa\">Math<\/span>.floor(<span style=\"color:#0aa\">Math<\/span>.random()*obfuscate.dict.length)] + \n    <span style=\"color:#a50\">'&amp;cm='<\/span> + obfuscate.medium[<span style=\"color:#0aa\">Math<\/span>.floor(<span style=\"color:#0aa\">Math<\/span>.random()*obfuscate.medium.length)];\n}\n_o_hitPayload += <span style=\"color:#a50\">'&amp;uip='<\/span> + \n  (<span style=\"color:#0aa\">Math<\/span>.floor(<span style=\"color:#0aa\">Math<\/span>.random() * <span style=\"color:#099\">255<\/span>) + <span style=\"color:#099\">1<\/span>) + <span style=\"color:#a50\">'.'<\/span> +\n  (<span style=\"color:#0aa\">Math<\/span>.floor(<span style=\"color:#0aa\">Math<\/span>.random() * <span style=\"color:#099\">255<\/span>) + <span style=\"color:#099\">0<\/span>) + <span style=\"color:#a50\">'.'<\/span> +\n  (<span style=\"color:#0aa\">Math<\/span>.floor(<span style=\"color:#0aa\">Math<\/span>.random() * <span style=\"color:#099\">255<\/span>) + <span style=\"color:#099\">0<\/span>) + <span style=\"color:#a50\">'.'<\/span> +\n  (<span style=\"color:#0aa\">Math<\/span>.floor(<span style=\"color:#0aa\">Math<\/span>.random() * <span style=\"color:#099\">255<\/span>) + <span style=\"color:#099\">0<\/span>);\n_o_hitPayload += <span style=\"color:#a50\">'&amp;aip=1'<\/span>;\n<\/code><\/pre>\n<\/div>\n<p>Modifying the IP addresses like this leads to interesting data in the list of service providers:<\/p>\n<div style=\"aspect-ratio: 1344 \/ 1068;\" class=\"figure nocaption\">\n<p>    <a href=\"https:\/\/www.simoahava.com\/images\/2019\/01\/service-providers.jpg\" title=\"service providers\"><\/p>\n<p>    <img decoding=\"async\" class=\"fig-img\" height=\"1068\" width=\"1344\" loading=\"lazy\" src=\"https:\/\/www.simoahava.com\/images\/2019\/01\/service-providers.jpg#ZgotmplZ\" alt=\"service providers\"\/><\/p>\n<p>    <\/a><\/p>\n<\/div>\n<p>The last thing that happens is that the hit is <strong>dispatched<\/strong> to the Tracking ID you provided.<\/p>\n<div class=\"highlight\">\n<pre style=\"background-color:#fff;-moz-tab-size:4;-o-tab-size:4;tab-size:4\"><code class=\"language-javascript\" data-lang=\"javascript\">sendHitTaskModel.set(<span style=\"color:#a50\">'hitPayload'<\/span>, _o_hitPayload, <span style=\"color:#00a\">true<\/span>);\noriginalSendHitTask(sendHitTaskModel);\n<\/code><\/pre>\n<\/div>\n<h2 id=\"caveats\">Caveats<\/h2>\n<p>It\u2019s not a <strong>perfect<\/strong> duplication of the data. Here are some the things the script has trouble with:<\/p>\n<ul>\n<li>\n<p>All campaign information from the original hit is removed. So the assignment of source\/medium information will not follow the logic of the original account. To counter this, I generate a random source\/medium to 10% of all hits.<\/p>\n<\/li>\n<li>\n<p>The prices are modified with the same <strong>percentage<\/strong>, not the same value. Thus, if you have a Transaction Revenue of <code>10.00<\/code> and Product Revenue of <code>8.00<\/code>, and the modifier is <code>0.8<\/code>, the end result will be a Transaction Revenue of <code>8.00<\/code> and Product Revenue of <code>6.40<\/code>. This means that someone <em>could<\/em> deduce what the original price was, if they assumed, for example, that Transaction Revenue is the total sum of all Product Revenus multiplied by their quantities (as it often is).<\/p>\n<\/li>\n<li>\n<p>No integer values are modified. So Custom Metrics, Event Values, quantities, and so forth are not touched. I did this because I don\u2019t think integers encode information that could be used to identify the original source of the data. Prices are modified because with a specific set of prices a user could guess what the origin of the data was, but not so much with integers. I\u2019m happy to modify this in the future if enough people think it\u2019s necessary.<\/p>\n<\/li>\n<\/ul>\n<h2 id=\"final-thoughts\">Final thoughts<\/h2>\n<p>Whether this solution is useful not, I can guarantee that writing it was a lot of <strong>fun<\/strong>! Just obfuscating the data would have been easy. Just mask every string with a random GUID or something. But trying to figure out a dictionary substitution was far more difficult.<\/p>\n<p>The algorithm I chose (with Jaakko Ojalehto\u2019s help) for the replacement isn\u2019t perfect. The distribution isn\u2019t even. But I think that\u2019s OK. You\u2019ll only end up with 420 words by default anyway, so there\u2019s going to be a LOT of overlap nevertheless, since even a simple site will produce far more than 420 unique strings in the data.<\/p>\n<div style=\"aspect-ratio: 1698 \/ 1066;\" class=\"figure nocaption\">\n<p>    <a href=\"https:\/\/www.simoahava.com\/images\/2019\/01\/page-titles.jpg\" title=\"Obfuscated titles\"><\/p>\n<p>    <img decoding=\"async\" class=\"fig-img\" height=\"1066\" width=\"1698\" loading=\"lazy\" src=\"https:\/\/www.simoahava.com\/images\/2019\/01\/page-titles.jpg#ZgotmplZ\" alt=\"Obfuscated titles\"\/><\/p>\n<p>    <\/a><\/p>\n<\/div>\n<p>Even if you don\u2019t find this dataset useful, I\u2019ll guarantee you\u2019ll have fun looking at the string combinations produced by the replacement algorithm. In fact, I had to modify the dictionary I initially had, because it resulted in compounds like <code>beat-child sweet-laughter<\/code> which I think might raise some eyebrows when the data is displayed in a training session.<\/p>\n<p>Let me know in the comments if this solution needs improvement!<\/p>\n<\/p><\/div>\n\n","protected":false},"excerpt":{"rendered":"<p>Perhaps you didn\u2019t know this, but there\u2019s a really handy demo account for Google Analytics you can use to check out how Google Analytics works in a real business context (the data is from the Google Merchandise Store). However, you can access the account with nothing more than read-only access. This is annoying if you [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":101350,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[12033],"tags":[12765,11603,14494,1531,47058],"dealstore":[],"offerexpiration":[],"class_list":["post-101349","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-analytics","tag-analytics","tag-data","tag-duplicate","tag-google","tag-obfuscate"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v26.4 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>Obfuscate And Duplicate Google Analytics Data - Som2ny Network<\/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:\/\/fivemor.com\/?p=101349\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Obfuscate And Duplicate Google Analytics Data - Som2ny Network\" \/>\n<meta property=\"og:description\" content=\"Perhaps you didn\u2019t know this, but there\u2019s a really handy demo account for Google Analytics you can use to check out how Google Analytics works in a real business context (the data is from the Google Merchandise Store). However, you can access the account with nothing more than read-only access. This is annoying if you [&hellip;]\" \/>\n<meta property=\"og:url\" content=\"https:\/\/fivemor.com\/?p=101349\" \/>\n<meta property=\"og:site_name\" content=\"Som2ny Network\" \/>\n<meta property=\"article:published_time\" content=\"2025-02-21T11:11:20+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/fivemor.com\/wp-content\/uploads\/2025\/02\/obfuscated-real-time.jpg\" \/>\n\t<meta property=\"og:image:width\" content=\"1568\" \/>\n\t<meta property=\"og:image:height\" content=\"742\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/jpeg\" \/>\n<meta name=\"author\" content=\"admin\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"admin\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"12 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\/\/fivemor.com\/?p=101349#article\",\"isPartOf\":{\"@id\":\"https:\/\/fivemor.com\/?p=101349\"},\"author\":{\"name\":\"admin\",\"@id\":\"https:\/\/fivemor.com\/#\/schema\/person\/b85e3c3dc0e1daea076524dc8810c371\"},\"headline\":\"Obfuscate And Duplicate Google Analytics Data\",\"datePublished\":\"2025-02-21T11:11:20+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/fivemor.com\/?p=101349\"},\"wordCount\":1394,\"commentCount\":0,\"publisher\":{\"@id\":\"https:\/\/fivemor.com\/#organization\"},\"image\":{\"@id\":\"https:\/\/fivemor.com\/?p=101349#primaryimage\"},\"thumbnailUrl\":\"https:\/\/fivemor.com\/wp-content\/uploads\/2025\/02\/obfuscated-real-time.jpg\",\"keywords\":[\"Analytics\",\"Data\",\"Duplicate\",\"Google\",\"Obfuscate\"],\"articleSection\":[\"Analytics\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\/\/fivemor.com\/?p=101349#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/fivemor.com\/?p=101349\",\"url\":\"https:\/\/fivemor.com\/?p=101349\",\"name\":\"Obfuscate And Duplicate Google Analytics Data - Som2ny Network\",\"isPartOf\":{\"@id\":\"https:\/\/fivemor.com\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/fivemor.com\/?p=101349#primaryimage\"},\"image\":{\"@id\":\"https:\/\/fivemor.com\/?p=101349#primaryimage\"},\"thumbnailUrl\":\"https:\/\/fivemor.com\/wp-content\/uploads\/2025\/02\/obfuscated-real-time.jpg\",\"datePublished\":\"2025-02-21T11:11:20+00:00\",\"breadcrumb\":{\"@id\":\"https:\/\/fivemor.com\/?p=101349#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/fivemor.com\/?p=101349\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/fivemor.com\/?p=101349#primaryimage\",\"url\":\"https:\/\/fivemor.com\/wp-content\/uploads\/2025\/02\/obfuscated-real-time.jpg\",\"contentUrl\":\"https:\/\/fivemor.com\/wp-content\/uploads\/2025\/02\/obfuscated-real-time.jpg\",\"width\":1568,\"height\":742},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/fivemor.com\/?p=101349#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/fivemor.com\/?bp_activities=1\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Obfuscate And Duplicate Google Analytics Data\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/fivemor.com\/#website\",\"url\":\"https:\/\/fivemor.com\/\",\"name\":\"Som2ny Network\",\"description\":\"Daily Deals\",\"publisher\":{\"@id\":\"https:\/\/fivemor.com\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/fivemor.com\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Organization\",\"@id\":\"https:\/\/fivemor.com\/#organization\",\"name\":\"Som2ny Network\",\"url\":\"https:\/\/fivemor.com\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/fivemor.com\/#\/schema\/logo\/image\/\",\"url\":\"https:\/\/fivemor.com\/wp-content\/uploads\/2026\/07\/4a0953c4-logo-300x86-1.png\",\"contentUrl\":\"https:\/\/fivemor.com\/wp-content\/uploads\/2026\/07\/4a0953c4-logo-300x86-1.png\",\"width\":300,\"height\":86,\"caption\":\"Som2ny Network\"},\"image\":{\"@id\":\"https:\/\/fivemor.com\/#\/schema\/logo\/image\/\"}},{\"@type\":\"Person\",\"@id\":\"https:\/\/fivemor.com\/#\/schema\/person\/b85e3c3dc0e1daea076524dc8810c371\",\"name\":\"admin\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/fivemor.com\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/729ae85bf62b9917e93538db2f2688ca?s=96&r=g&default=https%3A%2F%2Ffivemor.com%2Fwp-content%2Fplugins%2Fbuddypress-first-letter-avatar%2Fimages%2Fdefault%2F96%2Flatin_a.png\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/729ae85bf62b9917e93538db2f2688ca?s=96&r=g&default=https%3A%2F%2Ffivemor.com%2Fwp-content%2Fplugins%2Fbuddypress-first-letter-avatar%2Fimages%2Fdefault%2F96%2Flatin_a.png\",\"caption\":\"admin\"},\"sameAs\":[\"https:\/\/fivemor.com\"],\"url\":\"https:\/\/fivemor.com\/?author=1\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Obfuscate And Duplicate Google Analytics Data - Som2ny Network","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:\/\/fivemor.com\/?p=101349","og_locale":"en_US","og_type":"article","og_title":"Obfuscate And Duplicate Google Analytics Data - Som2ny Network","og_description":"Perhaps you didn\u2019t know this, but there\u2019s a really handy demo account for Google Analytics you can use to check out how Google Analytics works in a real business context (the data is from the Google Merchandise Store). However, you can access the account with nothing more than read-only access. This is annoying if you [&hellip;]","og_url":"https:\/\/fivemor.com\/?p=101349","og_site_name":"Som2ny Network","article_published_time":"2025-02-21T11:11:20+00:00","og_image":[{"width":1568,"height":742,"url":"https:\/\/fivemor.com\/wp-content\/uploads\/2025\/02\/obfuscated-real-time.jpg","type":"image\/jpeg"}],"author":"admin","twitter_card":"summary_large_image","twitter_misc":{"Written by":"admin","Est. reading time":"12 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/fivemor.com\/?p=101349#article","isPartOf":{"@id":"https:\/\/fivemor.com\/?p=101349"},"author":{"name":"admin","@id":"https:\/\/fivemor.com\/#\/schema\/person\/b85e3c3dc0e1daea076524dc8810c371"},"headline":"Obfuscate And Duplicate Google Analytics Data","datePublished":"2025-02-21T11:11:20+00:00","mainEntityOfPage":{"@id":"https:\/\/fivemor.com\/?p=101349"},"wordCount":1394,"commentCount":0,"publisher":{"@id":"https:\/\/fivemor.com\/#organization"},"image":{"@id":"https:\/\/fivemor.com\/?p=101349#primaryimage"},"thumbnailUrl":"https:\/\/fivemor.com\/wp-content\/uploads\/2025\/02\/obfuscated-real-time.jpg","keywords":["Analytics","Data","Duplicate","Google","Obfuscate"],"articleSection":["Analytics"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/fivemor.com\/?p=101349#respond"]}]},{"@type":"WebPage","@id":"https:\/\/fivemor.com\/?p=101349","url":"https:\/\/fivemor.com\/?p=101349","name":"Obfuscate And Duplicate Google Analytics Data - Som2ny Network","isPartOf":{"@id":"https:\/\/fivemor.com\/#website"},"primaryImageOfPage":{"@id":"https:\/\/fivemor.com\/?p=101349#primaryimage"},"image":{"@id":"https:\/\/fivemor.com\/?p=101349#primaryimage"},"thumbnailUrl":"https:\/\/fivemor.com\/wp-content\/uploads\/2025\/02\/obfuscated-real-time.jpg","datePublished":"2025-02-21T11:11:20+00:00","breadcrumb":{"@id":"https:\/\/fivemor.com\/?p=101349#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/fivemor.com\/?p=101349"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/fivemor.com\/?p=101349#primaryimage","url":"https:\/\/fivemor.com\/wp-content\/uploads\/2025\/02\/obfuscated-real-time.jpg","contentUrl":"https:\/\/fivemor.com\/wp-content\/uploads\/2025\/02\/obfuscated-real-time.jpg","width":1568,"height":742},{"@type":"BreadcrumbList","@id":"https:\/\/fivemor.com\/?p=101349#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/fivemor.com\/?bp_activities=1"},{"@type":"ListItem","position":2,"name":"Obfuscate And Duplicate Google Analytics Data"}]},{"@type":"WebSite","@id":"https:\/\/fivemor.com\/#website","url":"https:\/\/fivemor.com\/","name":"Som2ny Network","description":"Daily Deals","publisher":{"@id":"https:\/\/fivemor.com\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/fivemor.com\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/fivemor.com\/#organization","name":"Som2ny Network","url":"https:\/\/fivemor.com\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/fivemor.com\/#\/schema\/logo\/image\/","url":"https:\/\/fivemor.com\/wp-content\/uploads\/2026\/07\/4a0953c4-logo-300x86-1.png","contentUrl":"https:\/\/fivemor.com\/wp-content\/uploads\/2026\/07\/4a0953c4-logo-300x86-1.png","width":300,"height":86,"caption":"Som2ny Network"},"image":{"@id":"https:\/\/fivemor.com\/#\/schema\/logo\/image\/"}},{"@type":"Person","@id":"https:\/\/fivemor.com\/#\/schema\/person\/b85e3c3dc0e1daea076524dc8810c371","name":"admin","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/fivemor.com\/#\/schema\/person\/image\/","url":"https:\/\/secure.gravatar.com\/avatar\/729ae85bf62b9917e93538db2f2688ca?s=96&r=g&default=https%3A%2F%2Ffivemor.com%2Fwp-content%2Fplugins%2Fbuddypress-first-letter-avatar%2Fimages%2Fdefault%2F96%2Flatin_a.png","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/729ae85bf62b9917e93538db2f2688ca?s=96&r=g&default=https%3A%2F%2Ffivemor.com%2Fwp-content%2Fplugins%2Fbuddypress-first-letter-avatar%2Fimages%2Fdefault%2F96%2Flatin_a.png","caption":"admin"},"sameAs":["https:\/\/fivemor.com"],"url":"https:\/\/fivemor.com\/?author=1"}]}},"_links":{"self":[{"href":"https:\/\/fivemor.com\/index.php?rest_route=\/wp\/v2\/posts\/101349","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/fivemor.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/fivemor.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/fivemor.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/fivemor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=101349"}],"version-history":[{"count":0,"href":"https:\/\/fivemor.com\/index.php?rest_route=\/wp\/v2\/posts\/101349\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/fivemor.com\/index.php?rest_route=\/wp\/v2\/media\/101350"}],"wp:attachment":[{"href":"https:\/\/fivemor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=101349"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/fivemor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=101349"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/fivemor.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=101349"},{"taxonomy":"dealstore","embeddable":true,"href":"https:\/\/fivemor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fdealstore&post=101349"},{"taxonomy":"offerexpiration","embeddable":true,"href":"https:\/\/fivemor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fofferexpiration&post=101349"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}