Skip to content
All work

Toki

Mac · My ProductApp Store
Toki — app screenshots

Overview

Toki is a privacy-first automatic time tracker for macOS. It runs quietly in the background, works out what you’re doing from the app in front of you, categorizes your time without you touching a timer, and gives you a visual timeline plus stats like focused time, distractions, breaks and most-used apps.

My role

My first solo product. I designed it, built it, shipped it to the Mac App Store and market it. I built it to be mindful of how and where I work, then released it.

Hardest part

Sampling the frontmost app on a timer gives you thousands of fragments, not a timeline. Switch to Slack for four seconds and back, and a naive tracker records three sessions. Walk away for lunch and it records two hours of “work”.

I turned the raw samples into readable sessions by merging consecutive entries of the same app and category, and cutting a session when the gap crosses an idle threshold. Sleep and wake events are observed directly so time with the lid closed is never counted, and the sampling frequency adapts so a tracker that runs all day stays cheap on CPU and battery.

Architecture & stack

Swift and SwiftUI on macOS, MVVM, with AppKit and NSWorkspace for frontmost-app detection and sleep/wake events.

Core Data for storage, entirely on device with private CloudKit sync. A separate helper app handles launch at login, StoreKit powers the trial and subscription, and browser activity is enriched with cached favicons so websites show up in the timeline like apps do.

Achievements

  • My first solo product, live on the Mac App Store