Find answers about implementation, virtual try-on, product visualization, integrations, analytics, and account support.
Analytics Setup for Self-Service Integration - Migration to GA4
On July 1, 2023, standard Universal Analytics properties will stop processing data, according to Google Analytics Support. To complete the GA4 migration, some actions may be required, such as removing or adding some code.
GA3
Please find the analytics integration document for integrating GA3 with the old snippet example.
Before switching to GA4, the following code section was used to collect data in GA3 (Universal Analytics).
window.tangibleeAnalytics('setAnalyticsPlugin', 'GoogleAnalytics', {
trackingId: 'UA-XXXXXXXX-01',
ecommerceTracking: false
});
window.tangibleeAnalytics('setAnalyticsPlugin', 'GoogleAnalytics', {
trackingId: 'UA-XXXXXXXX-02',
inPageAnalytics: true,
trackerName: '',
useCustomerTrackingId: false,
ecommerceTracking: false,
customTangibleeDimension: 16,
customWidgetDimension: 17,
customWidgetSessionDimension: 18,
customTangibleeSessionDimension: 19,
customTangibleeUserDimension: 20
});Migration to GA 4
To switch to GA4, please, follow these steps:
- Remove the code section that collects data for GA3 (code example is indicated above).
- Add the following code to replace the removed one.
tangiblee('onGoogleAnalyticsIsReady', function(trackingId, analyticsSettings) {
window.tangibleeAnalytics =
window.tangibleeAnalytics ||
function() {
(window.tangibleeAnalytics.q = window.tangibleeAnalytics.q || []).push(arguments);
};
if(analyticsSettings.sendGAEventsViaInfoPortal === true) {
//Collection of GA4 analytics for Tangiblee
window.tangibleeAnalytics('setAnalyticsPlugin', 'InfoPortalAnalyticsForGA4', {
trackingId: analyticsSettings.tangibleeMeasurementId,
});
}
if(analyticsSettings.sendGAEventsDirectly === true) {
//Collection of GA4 analytics for Tangiblee
window.tangibleeAnalytics('setAnalyticsPlugin', 'GoogleAnalytics4', {
trackingId: analyticsSettings.tangibleeMeasurementId,
});
//Your GA4 analytics
analyticsSettings.clientMeasurementId && window.tangibleeAnalytics('setAnalyticsPlugin', 'GoogleAnalytics4', {
trackingId: analyticsSettings.clientMeasurementId,
currentDataLayerName: analyticsSettings.clientDataLayerName,
isCustomerGA: true,
/* If you are using GTM to collect analytics, you will need to unmute this config
gtmConfig: {
enabled: true,
events: {
impressed: 'tng_impressed',
interacted: 'tng_interacted'
}
}*/
});
}
});References
GA4 移行, Universal 分析 sunset, self-サービス 連携, 分析 code update, イベント 移行, tracking upgrade
GA4 移行 手順 向け self-サービス integrationsを正しく実装するための記事です。設定手順、スクリプト、タグ、API、コールバックなどの要点を整理し、プラットフォーム連携、公開リスクの低減、技術課題の早期解決に役立ちます。実装担当者が確認すべき前提条件もまとめて把握できます。導入前に確認すべきポイントも補足しています。関係者間のすり合わせにも役立ちます。公開準備の判断材料としても使えます。