Track Claude Code session duration with automatic timestamps, elapsed time skill, and optional status line integration
Reset the session timer to zero, restarting the elapsed time counter
Show session history with duration totals, optionally filtered by date range or project
Retroactively tag (or clear) the issue key on an already-ended session inside history.jsonl
Tag the current session with an issue key (e.g. LIN-456) so the worklog groups time against the right ticket
Group session history by issue key and propose postings to any connected MCP (Linear, Jira, Notion, ...)
Use when user asks to reset, restart, or zero out the session timer. Trigger phrases include "reset timer", "restart session time", "reiniciar tempo", "zerar timer".
Use when user asks about past sessions, worklog, accumulated hours, "quanto trabalhei hoje", "worklog do dia", "histórico de sessões", "horas trabalhadas", "session history", or wants to review time spent on projects across sessions.
Use when user asks about session duration, elapsed time, how long they've been working, or "quanto tempo". Also use when any skill or workflow needs to know session elapsed time.
No model invocation
Executes directly as bash, bypassing the AI model
Own this plugin?
Verify ownership to unlock analytics, metadata editing, and a verified badge. GitHub access is read-only (username + org membership).
Sign in to claimOwn this plugin?
Verify ownership to unlock analytics, metadata editing, and a verified badge. GitHub access is read-only (username + org membership).
Sign in to claimBased on adoption, maintenance, documentation, and repository signals. Not a security audit or endorsement.
Track Claude Code session duration with automatic timestamps.
CLAUDE_SESSION_FILE env varUserPromptSubmit and Stop hooks record turn boundaries; gaps longer than SESSION_IDLE_THRESHOLD_SECONDS (default 300s) are counted as idle, so you can see real working time vs the AFK gaps/session-tracker:session-status skill - check elapsed time, plus today's accumulated total/session-tracker:session-history command + skill - review past sessions filtered by date or project/session-tracker:reset-session command - reset the timer to zero/clear - clearing the session automatically restarts the timer# Add as a standalone marketplace plugin
claude plugin marketplace add aguinaldotupy/claude-session-tracker
# Install the plugin
claude plugin install session-tracker@aguinaldotupy --scope user
# Restart Claude Code to activate hooks
git clone https://github.com/aguinaldotupy/claude-session-tracker.git
claude --plugin-dir ./claude-session-tracker
# Clone into the plugins directory
git clone https://github.com/aguinaldotupy/claude-session-tracker.git \
~/.claude/plugins/marketplaces/claude-session-tracker
Then enable in ~/.claude/settings.json:
{
"enabledPlugins": {
"session-tracker@claude-session-tracker": true
}
}
Inside a Claude Code session:
/plugin
Navigate to the Installed tab - session-tracker should appear.
Type /session-tracker:session-status or ask naturally:
Example output:
Session: 1h 23m (active: 48m, idle: 35m, started at 14:30)
Idle is the sum of gaps between Claude finishing a turn (Stop) and your next prompt that exceeded SESSION_IDLE_THRESHOLD_SECONDS (default 300). Tune it by setting the env var, e.g. export SESSION_IDLE_THRESHOLD_SECONDS=180 for a stricter 3-minute cutoff.
Type /session-tracker:reset-session or ask naturally:
The timer resets to zero from the current time. The /clear command also resets the timer automatically.
Each time a session ends, the SessionEnd hook appends one JSON line to ~/.claude/session-env/history.jsonl with the session id, start/end timestamps, duration in seconds, project directory, and exit reason.
Query it with /session-tracker:session-history or ask naturally:
The command accepts an optional date filter (today, yesterday, 7d, 30d, or YYYY-MM-DD..YYYY-MM-DD) and an optional --project <substring> filter. It prints a markdown table of sessions plus a total. See commands/session-history.md and skills/session-history/SKILL.md for details.
/session-tracker:session-status also reports today's accumulated total (previous completed sessions plus the current live elapsed).
Each finished session is tagged with an issue key (e.g. LIN-456, ABC-123) so the worklog can group time per ticket.
Resolution order used by the SessionEnd hook:
/session-tracker:tag LIN-456 — stored at ~/.claude/session-env/<session_id>/issue-tag.[A-Z][A-Z0-9_]+-[0-9]+ match on the current git branch (works with common conventions like feat/LIN-456-title).issue_key are treated as empty.Tag the current session mid-flight:
/session-tracker:tag LIN-456
/session-tracker:tag --clear
Forgot to tag? Retroactively fix any session that already ended without an issue key:
/session-tracker:tag-session abc12345 LIN-456 # tag an old session by id prefix
/session-tracker:tag-session abc12345 --clear # blank the tag again
The worklog flow itself also offers inline retroactive tagging — when it spots an "Untagged" bucket, it walks you through each session and lets you tag, batch-tag, or skip before anything is posted to your MCP.
Then post your worklog to whichever issue tracker MCP you have connected:
npx claudepluginhub aguinaldotupy/claude-session-tracker --plugin session-trackerShows the local time on every message and tells Claude when each prompt was sent — so you can scan a conversation, see how long things took, and reference earlier blocks.
Track and summarize all files used during a Claude Code session
Meta-Cognition tool for Claude Code: session history analysis, workflow optimization, and 21 MCP tools for deep session insights.
Live usage status bar for Claude Code — session limits, weekly usage, lines changed, 10 themes, widget priorities, shimmer animations, and zero API calls
Harness-native ECC operator layer - 67 agents, 271 skills, 92 legacy command shims, reusable hooks, rules, selective install profiles, and production-ready workflows for Claude Code, Codex, OpenCode, Cursor, and related agent harnesses
Superpowers Plus core skills library for Claude Code: planning, execution routing, TDD, debugging, and collaboration workflows