I am trying to synchronise multiple clients to trigger a time sensitive event at the exact same time using firebase realtime database.
One client sets the serverTimestamp into a document, and all others use it to calculate when to trigger the event based on this “server” timestamp.
Problem: serverTimestamp is different when read on each client, with a difference of several hundred milliseconds. This is true for 2 browsers running on the same machine – so its not UTC time diff.
My first guess was that firebase is adding delay offsets (latency), but when i print .info/serverTimeOffset on each client, its comparatively very small, and always positive as it should be.
right now, its more accurate to use the sender client’s UTC time rather than this serverTimestamp.
So my question is, why is serverTimestamp is a different number when read on each client.