← Blog

Track your hours in Claude Code without a timer

Marcin Milinski · · 5 min read

You spend the afternoon in Claude Code. You describe the feature, the agent writes it, you review the diff, ask for a fix, run the tests, ask for another. At six you close the terminal, and the timesheet question comes up again: how long was that, and what do you write down?

A timer would have known, if you'd remembered to start it. Most of us don't, and a timer can't say what got done anyway. But Claude Code already keeps a full record of the session: every prompt, every reply, every tool call, each with a time. That's enough to work out the hours, and the work itself is right there in the conversation.

This post shows the setup we use ourselves to log our own work on ShiftLog.it: a skill that works out the hours from the session, writes the entry and logs it to your work log.

What you need

  • A ShiftLog.it account. Any plan works, Free included.
  • ShiftLog.it connected to Claude. ShiftLog.it is in Claude's connector directory, so you can add it on claude.ai in a few clicks, with no command to type, and it shows up in Claude Code signed in with the same account. Connect ShiftLog.it to Claude walks you through it, along with the one-line command if you'd rather add it in the terminal.
  • The example skill from our public repository, shiftlog-app/shiftlog-mcp: the examples/skills/shiftlog-my-style folder, with a SKILL.md and a small session_time.py script.
  • Python 3 for the script. If it's missing, Claude offers to install it, and only does after you say yes.

Copy the folder to ~/.claude/skills/ to use it in every project, or to a project's .claude/skills/ for that project only.

How it works

At the end of the session, ask Claude to log the work:

Log today's work.

Claude then:

  1. Runs session_time.py, which lists the session's prompts with their times.
  2. Picks where the work started: the prompt where you said "start timer", if you did, or otherwise your first request for actual work. Small talk and questions before it don't count.
  3. Adds up the active time from there. Gaps longer than 30 minutes count as breaks and are left out, so lunch doesn't end up on the invoice. The result is rounded to 15 minutes.
  4. Writes the entry from what you did in the session, and shows you the date, hours, client and description, with the start prompt and the active minutes, so you can correct anything.
  5. Logs it only after you confirm.

A typical answer looks like this:

Started at prompt 3 ("add retries to the payment webhooks"), 14:05 - 18:00,
3 h 15 min active (a 40-minute break left out) -> 3.25 h.

Date: 2026-11-23   Agent: Acme GmbH   Reference: 4f2c9a1
Topic: Webhook delivery retries
Description: Added automatic retries to outgoing payment webhooks, so a failed
delivery to the accounting system is tried again instead of being lost.
Covered by tests and checked on staging.

Log this?

Want the clock to start at a specific point? Say "start timer" in the prompt where the work begins. Worked on two things in one session? Ask for two tasks, and the script splits the session at the prompt where the second one started.

The hours you work, the work you ship

With an agent doing much of the typing, the hours say less about the work than they used to. What a client wants to see is what shipped and how you know it works. The session has both. Claude was there for the whole thing: it knows what you asked for, what changed and which tests ran. So it writes the description from the real work instead of your memory at the end of the day.

In a git repository, the skill also puts the commit's short hash in the task's reference. Months later, you or the client can go from the timesheet line straight to the code. If the work isn't committed yet, Claude says so and offers to log after you commit, rather than guessing a hash.

Make it yours

The skill is a plain text file with rules Claude follows, and the example is meant to be edited. Some of the rules it comes with:

  • Wording: past tense, one or two sentences a client can read, no file paths or jargon.
  • Clients: which work goes to which agent, e.g. "anything in the acme-* repositories goes to Acme GmbH".
  • References: a Jira ticket for one client, the commit hash for the rest.
  • Rounding: 15 minutes by default. Change --round for half hours.
  • Limits: never more than 8 hours in one task.

Delete what you don't need, change the examples, add your own. Write them the way you'd brief a colleague.

What it doesn't do

  • It measures the session, not your day. Time spent away from Claude Code doesn't count: a call, or reading docs in the browser for more than 30 minutes. If you were still working, say how long it took, and your number wins.
  • It works in Claude Code on your computer. A chat in Claude on the web or the desktop app has no transcript to read, so Claude asks you for the hours there. Everything else works the same.
  • It stays on your computer. The script reads the transcript where Claude Code saved it and sends nothing anywhere. Only the task you approve goes to ShiftLog.it.

Then, at the end of the month

The tasks land in your ShiftLog.it work log like any other, with your hourly rate. On the Reports page, pick the month and generate the timesheet as a PDF, with a CSV and, on paid plans, an Excel copy. The month you spent in Claude Code becomes a report the client can approve, without an evening of reconstructing it.

Create a free account, connect Claude Code and log today's session.

M

Marcin Milinski

Founder of ShiftLog.it. Writes about logging work, reporting hours to clients and the paperwork of working B2B.

@MarcinMilinski on X

Stop writing timesheets. Start sending them.

Set up in two minutes, and this month's report can be on its way today. Log what you did in a few words; ShiftLog.it turns it into a clear report that’s ready to send.

  • Free plan, no card needed
  • AI writes the boring part: every task description, every month
  • Upgrade or cancel whenever you like

ShiftLog.it © 2026 Softlane sp. z o.o. · Hours in. Reports out.