Back to Leanfinit

health fitness

Caffeine Curfew: See Exactly How Much Caffeine Is Still in Your System

A simple app that draws your caffeine decay curve, gives you a sleep-safe verdict, and tells you the latest you can safely have one more cup.

Artem

Founder

· 4 min read

Caffeine Curfew — home

You know caffeine keeps you awake. What you probably don't know is how much of this morning's coffee is still circulating at 10pm. The half-life of caffeine is roughly five to six hours, which means a 3pm cold brew leaves about a quarter of its caffeine in your bloodstream at midnight. You feel tired but your brain is still wired, and the connection between the afternoon drink and the restless night stays invisible.

Caffeine Curfew makes that invisible thing visible. Log your drinks, set your bedtime, and the app draws the full decay curve so you can see what's happening in your body across the whole day. Try the live demo in the phone frame on this page, then read on for how it works.

Live demo

Caffeine Curfew — running live, right here in the article · Open in a new tab

The problem no coffee app actually solves

Most coffee apps are about brewing: ratios, grind size, pour-over timings. A few let you count daily cups. None of them answer the question that actually matters for sleep: how much caffeine is still active in my body right now, and what will that number be at bedtime?

Sleep researchers have been clear on this for years. Consuming caffeine even six hours before bed measurably reduces total sleep time. People wearing sleep trackers routinely log poor nights without connecting them to the latte they had at 3pm, because the gap between cause and effect is too long to feel intuitively. Caffeine Curfew closes that gap with a single chart.

Caffeine Curfew — insights
Caffeine Curfew — insights

Log a drink in two taps

Open the app and you'll see a day already in motion, seeded with realistic drinks so the screen never feels empty. Tap the plus button to add your own. Pick from presets that cover the drinks people actually have: drip coffee, espresso, a latte, cold brew, matcha, tea, cola. Each preset comes with a sensible default caffeine dose, and you can edit the amount if your local shop pours a double shot by default.

Set the time, confirm, and the decay curve updates immediately. That's the whole logging flow. There's no account, no sync, no subscription nag. Everything stays on your device.

Caffeine Curfew — setup
Caffeine Curfew — setup

The curve that changes how you think about coffee

The chart is the heart of the app. It shows your total residual caffeine as a smooth curve from your first drink of the day through to well past your bedtime. Each drink adds its own arc, and the curves stack. You can see the spike from your morning espresso taper off, the second peak from lunch, and whatever is still left when you want to sleep.

At your bedtime, the app draws a threshold line, the level above which sleep is likely to be disrupted. The verdict at the top of the screen, green, orange, or red, tells you at a glance whether tonight is likely to go well. Orange means you might feel fine falling asleep but the quality will suffer. Red means you'll probably notice it.

Scroll forward on the curve or tap into the evening hours and you can see the exact milligrams projected at any point. It turns an abstract half-life equation into something you can actually reason about.

One more cup? The app tells you the latest safe time

The feature that earns its keep most days is the cut-off calculator. Tell the app your bedtime and it works backward from your sleep threshold to tell you the latest time you could have one more standard drink without pushing you into the red. If it's 2pm and the answer is 4:30pm, you still have options. If the answer was two hours ago, you know.

This is the kind of math nobody does in their head, not because it's hard, but because you'd need to remember the exact caffeine content of what you drank, when you drank it, and your personal bedtime, and then run the exponential decay mentally. The app does it in the background, continuously, and just shows you the answer.

Built for people who already care about sleep

Caffeine Curfew isn't trying to get you to drink less coffee. It's for people who already know sleep matters and already own a sleep tracker or at least pay attention to how they feel in the morning. The insight it offers is precision, not guilt. On a good day the verdict is green and you feel vindicated. On a bad day it tells you exactly what happened and you have information to act on tomorrow.

Knowledge workers pulling long days, students in exam season, and shift workers with irregular schedules all have one thing in common: caffeine is a tool they depend on, and they need it to not cost them sleep. The app works entirely offline and opens ready to use, because the moment you want to check something is usually the moment you're about to order another drink, not when you're sitting down to configure a wellness dashboard.

39

files in the build

39.9 MB

app bundle

Flutter Web

runs in any browser

Have an idea for a tool like this?

Caffeine Curfew started as a one-line idea and became a working, interactive app. If you have a problem you keep wishing someone would solve, you can build the tool yourself, no coding required.

Build your idea