Microsoft Clarity

Microsoft Clarity

Free heatmaps and session recordings

Easy5 min0% complete

What you need

  • A Microsoft account (free)
  1. 1.Click "Add new project"
  2. 2.Enter your website URL
  3. 3.Name the project
  4. 4.Click "Create"
  1. 1.Go to your project settings
  2. 2.Find the "Project ID" (a short alphanumeric code)
  3. 3.Copy it
💡The Project ID looks something like "abc123xyz"
# Add to your .env.local file:
CLARITY_PROJECT_ID=abc123xyz

Environment Variables

VariableDescriptionExample
CLARITY_PROJECT_IDYour Clarity project IDabc123xyz

Test Your Integration

After completing setup, try this prompt in Claude Code:

"Add Clarity tracking to my website"