Automatic time tracking in VS Code, Windsurf and Zed (the AI-editor guide)

Last updated: July 2026

Copilot's agent mode in VS Code, Cascade in Windsurf, the agent panel in Zed — the modern editor writes code with you, and often while you look away. That is a productivity win and a time-tracking headache: the billable work is real, but it no longer arrives as a tidy block you can point at. This guide covers what each of the three editors keeps on disk, why the ecosystem splits VS Code and Windsurf on one side from Zed on the other, and the honest options for turning any of it into billable hours without shipping your client's code to someone else's cloud.

Why AI editors break normal time tracking

Manual time tracking assumes a straight line: start the timer, do one task, stop it. An AI editor is the opposite. You describe a change, an agent edits half a dozen files while you read a diff, you switch to a second repository, then come back to review. If your timer only advances when you remember to click it, it will miss the stretches where the editor was working and you were reading — and those are billable. That start-stop rhythm is precisely why manual timers are estimated to miss anywhere from 15% to 40% of billable time.

The good news: all three editors already keep a detailed local record of what happened. The catch is that none of it is a time report, and where each editor keeps it — and how readable it is — differs.

What VS Code, Windsurf and Zed keep on disk

VS Code and Windsurf are close relatives — Windsurf is a fork of VS Code — so they store history the same way: SQLite state.vscdb databases under a per-workspace folder in ~/Library/Application Support/ (Code for VS Code, Windsurf for Windsurf), plus a global store. Copilot Chat and Cascade transcripts live inside those databases. If that sounds familiar, it is the same mechanism Cursor uses — a binary database you have to query rather than a log file you can follow. The Cursor guide has the deep dive; it applies almost verbatim here.

Zed is the odd one out. It is not a VS Code fork — it is a from-scratch editor written in Rust — so it has its own local data directory and its own agent-thread storage, and the VS Code extension ecosystem does not apply. What all three share is the important part: the timestamps and the project path you need are on your machine, for free. The missing piece is a tool that reads them and turns them into hours.

The extension split: VS Code and Windsurf vs Zed

Because VS Code and Windsurf share an extension format, the same plugins install in both. Zed has its own, smaller extension registry. That decides your tooling more than anything else.

WakaTime covers all three, but by different routes: a native VS Code extension that installs unchanged in Windsurf, and a dedicated Zed plugin. In each case you paste an API key and your coding activity — per project, file, branch and language — flows to a cloud dashboard. It is the richest way to understand how you code. The trade-off is unchanged from every other WakaTime setup: it is an account and a cloud, so it is not the pick when a client's code has to stay on your machine.

Terminal agents vs the editor’s own AI

Here is the distinction that actually decides how much you can automate. A lot of "AI editor" work is really a terminal agentClaude Code, Codex or Antigravity — running in the editor's integrated terminal. Those write plain, timestamped transcripts to disk, and a per-session tracker can read them no matter which editor hosts the terminal.

The editor's own assistant — Copilot in VS Code, Cascade in Windsurf, Zed's agent — is the harder case, because its history sits in the editor's private database. This is why Døgn auto-detects the terminal agents per session (Claude Code, Codex, Antigravity) but tracks editor-native AI the way it tracks any app: as part of your whole working day, with one-click and parallel timers and a 24-hour timeline that surfaces active-but-untracked stretches to assign. In practice: run Claude Code in your VS Code terminal and it is tracked automatically; lean on Copilot or Cascade and you assign that stretch with a click.

If the goal is getting paid

Metrics and dashboards are satisfying, but a freelancer needs billable hours per client and a line on an invoice — a different job. Døgn is built for that. Terminal-agent sessions are tracked automatically, each on its own line, with a short on-device summary as the description; everything else you assign in one click from the timeline. Each entry carries a client, a duration and a rate, all in local Core Data — no account, no cloud, no telemetry — and at month's end an HMAC-signed webhook hands the finished entries to a draft invoice. It is a one-time purchase, and plain billable time tracking, not a countdown or focus timer.

You can also point the editor's AI at Døgn directly: its local MCP server lists VS Code and Windsurf among supported clients, so you can start and stop timers by asking. See MCP & AI tools.

A setup you can do in five minutes

Settle the one thing that matters first — local or cloud — because an NDA usually makes the call:

  • Want deep metrics and fine with an account? Install the WakaTime plugin in your editor.
  • Want a local streak to stay motivated? trackmy.codes counts active coding time with no account.
  • Need to bill the time? Run Døgn in your menu bar: terminal agents track themselves, and you assign editor-native AI stretches once a week.

Whichever you pick, the win is the same: you stop reconstructing the month from memory and start from a record captured while you worked.

Questions, answered

Can I track time automatically in VS Code, Windsurf and Zed?

Yes, with a separate tool — none of the three reports billable time on its own. WakaTime installs in all three (a VS Code extension that also runs in Windsurf, plus a Zed plugin) for cloud metrics; trackmy.codes and Døgn keep everything local. Døgn additionally auto-detects terminal agents — Claude Code, Codex, Antigravity — running in the editor’s terminal.

Does Windsurf store data like VS Code?

Yes. Windsurf is a VS Code fork, so it uses the same SQLite state.vscdb databases under ~/Library/Application Support/Windsurf/ and installs the same extensions. Zed is a from-scratch editor and stores its history differently, in its own local data directory.

Does Døgn detect Copilot or Cascade sessions automatically?

Not per session. Døgn’s automatic session detection covers the terminal agents — Claude Code, Codex and Antigravity — where it also writes an on-device summary. Copilot, Cascade and Zed’s own agent are tracked as part of your whole working day instead: one-click and parallel timers plus a timeline that surfaces active-but-untracked stretches to assign.

Does WakaTime work in Zed?

Yes. Even though Zed is not a VS Code fork, WakaTime ships a dedicated Zed plugin you activate with your API key. As with any WakaTime setup, activity metadata goes to its cloud dashboard; if the data has to stay on your Mac, use trackmy.codes or Døgn instead.

Continue