Browsers routinely slow down JavaScript timers in tabs that aren't visible, to save battery and CPU — which is exactly the situation a countdown timer or stopwatch is often used in while you work in a different tab. Rather than counting ticks and hoping each one arrives on schedule, both the timer and stopwatch here record a real timestamp when they start and recompute the elapsed time from the actual clock (Date.now()) on every update. That means even if the browser skips or delays a tick while the tab is in the background, the display self-corrects to the true elapsed time the next time it updates, instead of drifting further off the longer it runs.
The two solve opposite problems: the timer counts down from a number you set toward zero and alerts you when it hits it — useful for anything with a fixed duration, like a work interval or something in the oven. The stopwatch counts up from zero with no set endpoint, which is what you want when you don't know the duration in advance and just need to measure how long something actually took. Switching between the two tabs doesn't stop or reset whichever one is running — it keeps counting in the background, just visually hidden — so it's safe to check the other mode mid-session and switch back without losing progress.
Yes — it's based on the actual system clock rather than a simple countdown, so it stays accurate even if the browser tab is in the background.
Yes, as long as your device's sound isn't muted and your browser allows audio playback.
The timer counts down from a set time and alerts you at zero. The stopwatch counts up from zero until you stop it — useful for timing how long something takes.