toggl-mcp
Fills Toggl Track time entries from Claude Code session transcripts: previews proposed entries for a date range (with per-day totals and cutting around existing Toggl entries and parallel sessions), then writes the confirmed plan, with per-entry description/start/stop overrides. Also checks the API token and lists workspaces and projects.
Reads Claude Code session activity to derive work time and session titles, previews them as proposed Toggl Track time entries within a date range (avoiding double-counting time already logged in any project), and creates the confirmed entries with the configured workspace, project, and tags.
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@toggl-mcpFill Toggl for yesterday"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
toggl-mcp
MCP server that fills Toggl Track from your Claude Code sessions: work time from session activity, descriptions from session titles, preview before writing.
Claude Code session transcripts already record when you worked on a task and what the session was about. preview_timesheet turns that into proposed time entries for a date range, cut around anything already in Toggl. create_time_entries writes them once you confirm. Runs locally over stdio; the API token is only sent to Toggl.
How time is counted
Activity comes from the Claude Code transcripts of each configured repo (
~/.claude/projects/<repo path with non-alphanumerics replaced by ->*/*.jsonl): every prompt, reply and tool call has a timestamp, the git branch and the working directory. Subagent activity counts too.One session becomes one or more entries: a pause longer than
idleGapMinends an entry, and each entry getstailMinextra minutes for reading the last answer. Entries shorter thanminEntryMinare dropped.Description: the session title in effect when the entry ended — the one you set with
/rename, otherwise the title Claude Code generates (the one in/resume). Sessions without a title use their first prompt.No minute is counted twice: proposed entries are cut around existing Toggl entries (in any project) and around each other when sessions run in parallel. Running the preview again after writing proposes nothing new.
Related MCP server: Toggl MCP Server
Setup
Requires Node 22+.
npm install
npm run buildGet the API token in Toggl Track → Profile settings → API Token, then register the server for all your Claude Code projects:
claude mcp add toggl --scope user -e TOGGL_API_TOKEN=<token> -- node /absolute/path/to/toggl-mcp/dist/index.jsCreate the config (default ~/.config/toggl-mcp/config.json, or point TOGGL_MCP_CONFIG at another file):
mkdir -p ~/.config/toggl-mcp
cp config.example.json ~/.config/toggl-mcp/config.jsonAsk Claude to run toggl_status: it checks the token and lists workspace and project ids for the config.
Config
{
"workspaceId": 1234567,
"timezone": "Europe/London",
"idleGapMin": 20,
"tailMin": 5,
"minEntryMin": 5,
"repos": [
{ "path": "~/projects/my-app", "projectId": 7654321, "tags": ["claude"] }
]
}field | default | |
| your default workspace | Toggl workspace for new entries |
| system timezone | how dates in requests and the preview are read |
| 20 | a pause longer than this ends an entry |
| 5 | minutes added after the last activity of an entry |
| 5 | shorter entries are dropped |
| — | repository root; |
| none | Toggl project for its entries |
|
| tags for its entries |
| derived from | Claude Code transcripts folder, if it lives elsewhere |
The config is read on every call, so edits apply without restarting.
Tools
tool | |
| checks the token, lists workspaces and projects with ids, shows the config |
| proposed entries for the days |
| writes a previewed plan; |
Typical use in Claude Code:
Fill Toggl for yesterday
Claude calls preview_timesheet, shows the table, and writes after you confirm — or with your edits ("drop #3, make #2 end at 18:30").
Plans live in memory until the server restarts.
Limits
Only time spent with Claude Code is visible. Work outside it (meetings, manual coding) is not tracked.
Activity is attributed by the working directory of the session: a session started in one repo counts for that repo, whatever it works on.
A long session that covers several tasks is described by its title at the time; rename the session (
/rename) when you switch tasks to get accurate descriptions.Toggl returns time entries for roughly the last three months.
Development
npm run dev # tsc --watch
npm test # node:test on src/ via type stripping
npx @modelcontextprotocol/inspector node dist/index.jsLicense
MIT
This server cannot be deployed
Maintenance
Related MCP Connectors
Billable-hours time tracking with rates and CSV export, running inside Claude or Cursor.
Track time in Clockify: time entries, projects, clients, tags and reports; start, stop and log time.
Connect Claude to Fathom meeting recordings, transcripts, and summaries
Connects AI assistants to TrackingTime for querying time entries, projects, tasks, customers, and team data using natural language.
Related MCP Servers
- -licenseAqualityNot gradedmaintenanceEnables natural language time tracking through Claude with markdown file storage. Supports multi-company tracking, flexible time parsing, auto-calculated summaries, and commitment warnings all through conversational input.1-
- AlicenseAqualityDmaintenanceEnables control of Toggl time tracking directly from LLMs like Claude or ChatGPT. Supports starting/stopping timers, viewing current and historical time entries, managing projects, and generating weekly summaries through natural language.817 npm3MIT
- AlicenseAqualityDmaintenanceEnables AI assistants to manage Toggl Track time entries, projects, and workspaces through natural language, supporting CRUD operations and past date time slots.137 npm2MIT
- FlicenseNot gradedqualityDmaintenanceEnables logging time to Tempo (Jira time tracker) via natural language in Claude Desktop or OpenCode.-