How AI Can Help You Stop Biting Your Nails: The Technology Behind Real-Time Detection
Technology · 4 min read · Updated
By Igor Gazivoda · Founder, Stop Biting
A software developer who bit his nails for over 20 years, not a clinician.
Real-time AI detection solves the awareness problem behind nail biting. Learn how webcam-based AI works, the HRT method it automates, and what to expect.
What is the core problem AI solves for nail biting?
The central challenge in stopping nail biting is not motivation — most nail biters want to stop — it is the automaticity of the habit. Research on habit behaviour consistently finds that nail biters are unaware of the majority of their daily biting episodes. The hand-to-mouth movement is executed below the threshold of conscious attention before any opportunity for deliberate intervention.
Habit Reversal Training's primary active ingredient is awareness training — systematically raising the threshold at which the person notices the habit occurring. But awareness training in its traditional form requires human support: a therapist, a partner, or an extremely disciplined self-monitoring practice. Real-time AI detection provides this awareness trigger automatically, at the exact moment the habit occurs, in any context where a camera is available.
How does webcam-based nail biting detection actually work?
Modern real-time nail biting detection uses a combination of hand landmark detection and face landmark detection to identify when fingers are near the mouth. The hand model tracks 21 key points on the hand; the face model tracks 478 facial landmarks including the precise location of the lips and mouth opening. When hand landmarks and mouth landmarks are simultaneously within a defined geometric proximity, the detection fires.
The underlying AI framework — MediaPipe, developed by Google — runs entirely in WebAssembly, a portable binary instruction format that executes at near-native speed inside browsers and desktop applications. This means detection can run entirely on the user's local CPU or GPU, so the video never has to be sent to a server to be analysed. Stop Biting deliberately runs it five times a second rather than on every frame — enough to catch a hand on its way to the mouth, at a fraction of the CPU cost. Detection runs on the device and no camera data is sent while it runs — a non-trivial privacy consideration for a tool that operates continuously during work hours.
For the two models, how often the check runs and how big the downloads are, see how MediaPipe detects nail biting in Stop Biting.
Is AI detection as effective as human awareness training?
The therapeutic mechanism is identical to the sensory interruption component of HRT — an external signal that breaks the automatic chain at the moment of occurrence. What AI detection adds over traditional methods is: real-time precision (the alarm fires at the exact moment, not after the bite has occurred); consistency (no lapses, no social awkwardness, no communication errors); and persistence (the system monitors continuously without fatigue or distraction).
Early user reports suggest a characteristic adaptation curve: weeks 1–2 see frequent alarms as the system captures the full scope of previously-unnoticed biting; weeks 3–4 show decreasing alarm frequency as awareness increases; weeks 5–8 show continued reductions as the competing response becomes habitual. This mirrors the timeline observed in clinical HRT studies — consistent with the hypothesis that the AI is activating the same underlying mechanism as the sensory interruption component of HRT.
What are the privacy implications of a webcam monitoring app?
Privacy is the central concern for any application that operates a webcam continuously during work hours. Stop Biting addresses this through architecture rather than policy: because MediaPipe runs entirely in WebAssembly on the user's device, no camera data — not a single frame — is sent while it runs. This can be independently verified by monitoring network traffic while detection runs; no camera data will be observed.
Your incident log and streaks are stored in your browser rather than synced to a server, and clearing the site's data removes them. Signing in and paying use the network, and the site counts page visits with Google Analytics, but none of that includes camera data. For anyone considering the trade-off of continuous camera monitoring against the therapeutic benefit, the data architecture makes the privacy case straightforwardly: the camera feed is processed and discarded on the device, frame by frame, and no camera data is sent while it runs.
What should I expect in the first month of using AI detection for nail biting?
The first week is typically the most disorienting. The alarm fires frequently — often far more frequently than the user expected based on their subjective sense of how often they bit. This is the most therapeutically important period: the gap between perceived and actual biting frequency becomes concretely visible. Some users find this discouraging; reframing it as data collection rather than failure is important.
The progression the method aims at runs in one direction: first you notice after the alarm, then as the hand moves, then before it moves at all. That last stage is the point, because it is the competing response firing on its own. How long each stage takes has not been measured in a controlled trial, so treat any week-by-week version of it as an expectation rather than a schedule. This progression from post-hoc alarm to proactive interception is the target outcome of the awareness training component of HRT — and it is the point at which durable habit change becomes possible.