/Reviewed November 13, 2026

How does a battery lock know what time it is?

A code that expires on Friday, a lobby that opens at nine, a card that stops working at a set moment: all of it assumes the lock knows the time, when it has no network and nobody to tell it.

A code that works Tuesday to Friday, a cleaning card good until noon, a schedule that unlocks the lobby at nine: every one of those rules assumes the lock enforcing it knows perfectly well what time it is. Without a clock it could not apply them at all. And yet a battery lock often has no network, and nobody tells it the time. So how does it manage?

The lock has a clock, set on the day it was fitted

Inside the lock is a real-time clock: a small quartz oscillator running off the battery, the same thing that drives a wristwatch. It gets set once, at installation or at pairing, when a phone or a programmer hands it the current time. After that the clock runs on its own.

What happens to it next depends on how the system reaches the lock, and there are two ways.

Either the system talks to the lock: by radio, through a bridge, or from the phone of somebody standing at the door. That is the , and the clock is usually reset at every exchange, without anyone asking for it.

Or the system never talks to it, which is the : it only writes onto the cards that will be used to unlock the door, or computes a code the lock will accept at certain hours. In that case the lock receives nothing new, and its date is whatever its oscillator has counted since the installer came to fit it.

And oscillators drift. Up to a dozen seconds a week, ten minutes a year, and more than that on an outdoor gate where the temperature swings. That's the accuracy a cheap quartz gives you, and lock firmware is written accordingly.

Twenty minutes of drift can block a perfectly valid code

A code valid from 15:00 starts working at 14:59 or at 15:01, and nobody notices. But once the device has fallen twenty minutes behind, the guest who turns up at the advertised check-in time and types the right code gets refused, because the lock reckons the code's window hasn't opened yet.

Twenty minutes of drift can block a perfectly valid codeThe guest arrives on time with the right code. The lock applies the right rule against the wrong time.
Two time rulers, one above the other. Above, real time from 14:30 to 15:30, on the guest's phone, with the code valid from 15:00. Below, the lock's clock, twenty minutes behind, from 14:10 to 15:10, with the same code valid from its own 15:00. A dashed line marks the moment the guest types the code: 15:00 in real time, 14:40 for the lock, where the code is not valid yet. An orange span shows the lock refusing the code until 15:20 real time. The lock pictured is an igloohome Mortise 2.
Twenty minutes of drift can block a perfectly valid codeThe guest arrives on time with the right code. The lock applies the right rule against the wrong time.
Two time rulers, one above the other. Above, real time from 14:30 to 15:30, on the guest's phone, with the code valid from 15:00. Below, the lock's clock, twenty minutes behind, from 14:10 to 15:10, with the same code valid from its own 15:00. A dashed line marks the moment the guest types the code: 15:00 in real time, 14:40 for the lock, where the code is not valid yet. An orange span shows the lock refusing the code until 15:20 real time. The lock pictured is an igloohome Mortise 2.
A clock set once at installation drifts: up to a dozen seconds a week, ten minutes a year, more on an outdoor gate. At that rate, twenty minutes is two years without a reset.

Nothing flags the failure. The lock applies its rule correctly but against the wrong time, and it has no way of knowing its clock is off.

From the support desk, the failure can look like a problem with the code. But issuing a new code produces exactly the same refusal. The real question is a different one: when was this lock's clock last set?

A lock's clock gets set the same way its rules do, by contact: a phone at the door, a programmer, any session where something talks to the lock. Across an offline estate, the visit schedule is therefore what determines how accurate the clocks are.

On some models, setting the clock is a command in the app

With some manufacturers, setting the time isn't a side effect of connecting. It's a named function the user triggers. igloohome's launch post for the Mortise 2 gives the action and its reason in the same sentence: "to ensure that your PIN codes work properly, you can sync the time of both your smartphone and Mortise", within Bluetooth range (igloohome).

So the drift is real enough that a manufacturer exposes a button for it, and the symptom it advertises isn't "the time is wrong" but "the codes don't work".

When the rights are written on the cards, the lock gets visitors all day

An offline lock isn't necessarily out of contact. The card is what carries the information, and it travels both ways. Salto describes how this works in its Space system: a holder's rights are written onto their card at a wall reader, the card then updates each door's denylist as it goes, and the lock, for its part, "transfers information such as audit trail events and, if the battery is low, the lock battery status" (Salto Space).

So the channel exists, and a lock we call offline uses it several times a day. Setting the clock is not what it is used for: Salto has each offline lock updated with a portable programming device "at least every six months to ensure that the clock and calendars are up to date" (Salto Space, PPD).

Who sets the clock, and how often
Online lockOffline lock, visitedOffline lock, forgotten
Time is setContinuously, by its connectionAt each app or programmer sessionOnce, years ago
Drift accumulates forHours at mostWeeks or monthsIts whole life
A time fault looks likeAlmost nothing: it heals itselfOccasional failures at the edge of a windowGood codes refused and expired cards accepted
Who noticesNobody has toWhoever visitsA guest, in the rain, at check-in

The last column describes any offline lock whose management app has been uninstalled. It goes on opening and refusing normally, on a time that drifts further out every week.

Validity windows are wide because the clock drifts

Validity windows are generous at their edges: demanding minute precision from a drifting oscillator would amount to stranding people outside. One-time codes often stay valid well past their nominal moment, for the same reason.

On long-lived offline installations, setting the time is part of the maintenance routine. It costs nothing and puts the drift back to zero.

And systems that do both, talking to the lock sometimes and relying on the credential the rest of the time, use their online moments to correct the clock: a lock that is rarely reachable spends part of every contact on exactly that.

Smart Locks
Access Systems
Lock Capabilities
Thermostats
Sensors
© 2026 Seam Labs, Inc.