- Help Center
- Integrations
- Microsoft Clarity
-
Getting Started
-
Configuration
- Targeting
- Split URL
- Product Testing
- Full Stack
- Experiment Management
- CSP Configuration
- Experiment Execution
- Reports
- Exit Popups
- GTM Integration
- Troubleshooting
- Performance Optimization
- Event-Triggered Changes
- Holdout Groups
- Split URL Pages
- URL Parameters
- DataLayer
- Menu Configurations
- Traffic Exclusion
- Experiment Scheduling
- Dynamic Element Changes
- Price Targeting
- Experience Scheduling
- Privacy
- Hash Changes
- Async Tracking
- Selective Installation
- CSS Selectors
- Vue.js Integration
- Page Content
- Multipage Split URL
- Organic Traffic
- Visual Editor
- Server-Side Testing
- Traffic Bucketing
- GDPR Warnings
- Statistical Confidence
- Browser Privacy
- Query Parameters
- Embedded Videos
- Tracking Code Execution
- Simultaneous Experiments
- Tags
- Deployments
- Disable Testing
- Locations
- Programmatic Bucketting
- Query Parameter Handling
- Convert Library
- Variation Previews
- Experiment Editing
- Opt-Out Script
- Data Reset
- Body Hiding
- Visit-Specific Variations
- Variation Styling
- Preview Issues
- Variation Editing
- Full-Site Testing
- Blinking Variations
- Cross-Domain Cookies
- Regex Support
- Conversion Tracking
- SPA Testing
- Project Setup
- Cross-Domain Tracking
- Geo-Targeting
- Analytics Tools
- Campaign Tags
- Previewing
- IDs
- Query String Targeting
- Bounce Rate Goals
- Bot Filtering
- Query String Variables
- Custom Audiences
- Redirects
- Baseline
- Tracking Code Location
- Secure Cookies
- AngularJS
- Cloudflare
- Code Installation
-
Track Goals
- Form Tracking
- Cookie Management
- iFrame Click Tracking
- Performance Optimization
- Revenue Tracking
- Interaction Goals
- Form Submissions
- Advanced Goals
- Lazy Loading
- Multi-Conversions
- URL Parameters
- Bounce Rate Goals
- DataLayer Integration
- Scroll Depth
- Social Interactions
- Page Views
- Marketo Forms
- Feature Analysis
- AJAX Forms
- Revenue Tracking via GTM
- Order Outliers
- Cumulative Revenue
- Goal Templates
- Adding Revenue Goals
- JS-Based Goals
- Goal Basics
- Google Analytics Goals
- Social Sharing
- Dynamic Goals
- Typeform Integration
-
Target Visitors
- Geolocation
- Interaction Goals
- Goal-Based Targeting
- Weather Targeting
- Cookie-Based Targeting
- Page Visits
- Audience Management
- Audience Segmentation
- Experiment Targeting
- Advanced Audience Creation
- Audience Templates
- Audience Creation
- Data Layer Integration
- Manual Activation
- JavaScript Conditions
- Device Targeting
- Language Targeting
- IP-Based Exclusion
- Visitor Management
- Page Tagging
- Cookies
-
Troubleshooting
- Google Warnings
- Visual Editor
- HTTPS Content
- Logs
- Support Options
- Bootstrap
- Cookie Blocking
- Change History
- Mobile Debugging
- AdWords
- Bot Exclusion
- Domain Issues
- Cloudflare Issues
- Monitoring
- Cloaking Penalties
- Goal Editor Issues
- Variations
- Snippet Performance
- Changes Not Saved
- Blocked Visual Editor
- Goal Testing
- Visual Editor Browsing
- Experiment Issues
- Installation Verification
- Data Leak Prevention
- Usage Limits
- Experiment Previews
- GA4 Revenue
- Chrome Debugger Logs
- SPA Errors
- Checkout JSON Error
-
Analyze Results
-
Integrations
- Google Analytics
- Cookie Consent Platforms
- Microsoft Clarity
- Plausible
- Marketo
- HubSpot
- Tealium
- Smartlook
- Klaviyo
- Salesforce CRM
- FullStory
- Snowplow Analytics
- Webflow
- GA4 Roles
- Amplitude
- Segment
- React
- BigCommerce
- WooCommerce
- Active Campaign
- Google Tag Manager
- Mixpanel
- Zapier
- Inspectlet
- Crazy Egg
- LanderApp
- Unbounce
- Instapage
- Drupal
- PrestaShop
- Magento
- Roistat
- Piano Analytics
- Heap Analytics
- Kissmetrics
- Mouseflow
- Adobe Analytics
- Clicky
-
Account Management
-
Developers
-
What's New
-
Common Questions
-
Shopify
Integrate Convert Experiences with Microsoft Clarity
This Article Will Help You:
- Convert-Microsoft Clarity Integration
- Sign Up at the Clarity Website
- Add Tracking Code Snippets
- Activate Convert-Clarity Integration
- View Convert Data in Clarity Dashboard
Convert-Microsoft Clarity Integration
Convert Experiences can integrate with Microsoft Clarity and this integration offers session replays and heatmaps per experience. Replaying sessions per variation is important for any agency and conversion rate optimization expert.
For each experiment, the integration uses custom instrumentation events to pass along the experiment name and variation name that the visitor is currently bucketed into.
Sign Up at the Clarity Website
Sign up at the Clarity website using your Microsoft or Facebook or Google account.
When you create a new Clarity project you will be able to retrieve the uniquely generated JavaScript code for your project.
Clarity works on any HTML webpage (desktop or mobile) after adding this small piece of JavaScript to the website. As soon as the script is added, Clarity receives your site’s data and you can start using Clarity.
The JavaScript code listens to browser events and instruments layout changes, network requests and user interactions. That data is then uploaded and stored in the Clarity server running on Microsoft Azure.
Add Tracking Code Snippets
Make sure the Convert tracking code and the Clarity JS code are installed on your page. Once you have added the codes to your website, you will be able to use the Clarity dashboard to start replaying user sessions and gain insights.
Activate Convert-Clarity Integration
Add the code below to your website right after the Convert + Clarity tracking codes which will send Convert Experience and Variation names to Clarity Dashboard. We are using custom tags:
This is the code you need to insert in your Your Project Configuration Global Project Javascript:
// Function to handle the data sending to another platform
function sendDataToPlatform(data) {
if (typeof clarity === "function") {
data.forEach(item => {
clarity("set", "Exp_Name", item.expName);
clarity("set", "Var_Name", item.varName);
console.log("Sent data to platform: Exp_Name =", item.expName, "Var_Name =", item.varName);
});
} else {
console.error("Clarity function is not available.");
}
}
// Function to check if a library (e.g., Clarity) is loaded, with a timeout
function whenAvailable(name, callback) {
const maxTime = 150 * 1000; // Maximum time to wait in milliseconds (2.5 minutes)
const interval = 100; // Poll every 100 milliseconds
let elapsedTime = 0; // Track the elapsed time
var intervalId = setInterval(function() {
if (window[name]) {
clearInterval(intervalId);
callback();
} else if (elapsedTime > maxTime) {
clearInterval(intervalId);
console.error(name + " library did not load in time.");
}
elapsedTime += interval;
}, interval);
}
// Convert snippet lifecycle hook for experiences evaluated
window._conv_q = window._conv_q || [];
window._conv_q.push({
what: 'addListener',
params: {
event: 'snippet.experiences_evaluated',
handler: () => {
console.log("All experiments have been evaluated");
// Prepare the data for each experiment and variation
const allData = Object.keys(convert.currentData.experiences).map(expId => {
const expData = convert.currentData.experiences[expId];
const variation = expData.variation;
let experimentName = convert.data.experiences.find(exp => exp.id === expId)?.name || 'Unknown Experiment';
return { expName: experimentName, varName: variation.name };
});
// Wait for the Clarity library to be available
whenAvailable('clarity', function() {
// Once Clarity is available, process and send data
sendDataToPlatform(allData);
});
}
}
});
View Convert Data in Clarity Dashboard
Using a custom tag in Clarity, you will be able to view all of your Convert Experiences data as they associate to the values that you pass in the tag.