Windsurf analytics for apps built with Windsurf | Orwel
Best practices Updated December 4, 2026

Windsurf analytics: add Orwel to an app built with Windsurf

To add analytics to an app built with Windsurf, now called Devin Desktop, give the agent the Orwel rules in AGENTS.md or a rules file, put the key in an environment variable, ask it to install and instrument, verify each request in Dev mode and add the Orwel MCP server to the editor's MCP config so it reads real usage.

Orwel is an event analytics SDK for startups, developers and vibe coders that maps feature adoption and conversion funnels, and feeds the results back to AI agents through MCP.

What this page covers

Windsurf is an AI editor that works inside your repository. In June 2026 it became Devin Desktop; the docs moved to docs.devin.ai and older Windsurf rules files are still read. This page uses both names.

It is about measuring the app you build with it, not about the editor's own usage stats. That is the measure step of the vibe coding loop.

Facts about the editor come from the Devin Desktop docs, last checked December 4, 2026. Menus are moving with the rename, so check the docs if a path below does not match what you see.

You need an Orwel workspace (the Free plan is enough to start) and your project open in the editor.

Step 1: Give the agent the rules

You have two options, and they combine well.

The Orwel skill. From the project root:

npx skills add hyperlabs-ai/hyper-skills/orwel

It works with agents that support skills, and teaches the agent the full SDK and its rules.

A rules file. The agent reads AGENTS.md at the project root and in subfolders. Paste the rules block from the CLAUDE.md analytics template there. For a rule of its own, create .devin/rules/orwel.md with a trigger that keeps it always on:

---
trigger: always_on
---

(paste the Orwel rules block here)

Existing .windsurf/rules/*.md files and a .windsurfrules file are still imported, so a project set up before the rename keeps working. You can manage rules from Customize, then Rules.

Step 2: Put the key in an environment variable

Copy the development key (orwel_dev_...) from your workspace into .env with the name your framework uses:

Framework Variable
Next.js NEXT_PUBLIC_ORWEL_KEY
SvelteKit, Astro PUBLIC_ORWEL_KEY
Vite (React, Vue, Svelte) VITE_ORWEL_KEY
Nuxt 3 NUXT_PUBLIC_ORWEL_KEY

Add an empty line for it in .env.example and make sure .env is in .gitignore. In production, set the variable to the production key (orwel_...) in your hosting provider.

Step 3: Ask the agent to install and instrument

Install Orwel in this project following the Orwel rules. Read the key from the env var for this
framework, create one wrapper module and init once on the client. Identify users when they sign
in and await a conversion with the email when they submit the contact form. Then propose an
event catalog from the service layer and wait for my confirmation.

The agent can run terminal commands on its own, within the allow, ask and deny rules you set, so it will run npm install orwel for you. Review the diff: track() codes must come from the catalog, events fire after the action succeeds and conversions are awaited. More prompts are in vibe coding prompts.

Step 4: Verify in Dev mode

Run the app with the development key and debug: true, then trigger a sign in, each tracked action and one form submit. Open Dev mode in Orwel:

  • Errors mean rejected: event_not_found, invalid_field, missing_session_id.
  • Warnings mean accepted with a problem: conversion_no_email, missing_attribution, identify_no_email.

Paste any warning back to the agent. Deploy with the production key once Dev mode is clean.

Step 5: Add the Orwel MCP server

The editor supports remote MCP servers over Streamable HTTP. In Orwel, open Settings, API keys and create a key with the mcp scope, set to server only. In the editor, open Customize, then MCPs, or create .devin/mcp_config.json in the project:

{
  "mcpServers": {
    "orwel": {
      "serverUrl": "https://api.orwel.io/mcp",
      "headers": { "Authorization": "Bearer orwel_sk_..." }
    }
  }
}

The docs show the address as serverUrl in one place and url in another, and say both are accepted. That key reads customer data, so keep the project file out of version control or use the user level config instead. On Teams and Enterprise an administrator may need to allow the server first.

On the Orwel Free plan the server answers with aggregated data; individual leads and visitors need Pro.

Step 6: Ask about real usage

  • "Show conversions and the issues Orwel detected in the last 14 days."
  • "Which campaign brought qualified leads?"
  • "How many leads came in this week compared with last week?"

That closes the vibe coding feedback loop. The same steps for other editors are in the Cursor and Claude Code guides.

Why Orwel

One plan

49 USD a month, 2 USD less every paid month down to 35 USD, or 420 USD a year

No caps

Unlimited leads and visitors under fair use

2-minute install

One script or npm package, or ask your coding agent to do it

MCP server

Claude, Cursor or your own agent read real usage before the next prompt

Semantic catalog

257 ready events, so tracking is named the same in every project

Dev mode

A live debugger and development keys that keep tests out of real data

FAQ

Is Windsurf now Devin Desktop?

Yes. The Windsurf editor became Devin Desktop in June 2026 and its docs moved to docs.devin.ai. Rules written for Windsurf are still imported.

Where do rules for analytics go in Windsurf?

In AGENTS.md at the project root, or in .devin/rules/ as a Markdown file with trigger: always_on. Older .windsurf/rules files and .windsurfrules still work.

How do I connect Orwel MCP to Windsurf?

Create an API key with the mcp scope in Orwel, then add a server with the address https://api.orwel.io/mcp and an Authorization: Bearer header, from Customize, MCPs or in .devin/mcp_config.json.

Which key goes in the app and which in the editor?

The app uses the development key locally and the production key in production, both from an environment variable. The MCP config uses an orwel_sk_ API key with the mcp scope, which must never be in browser code.

Is this about Windsurf's own analytics?

No. This page is about measuring the app you build: its users, feature adoption, conversion funnels and leads.

Keep reading

See what users do with what you shipped

Install in 2 minutes. Free to start, no card needed.