You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Analog clock card gets out of sync when page is left open for a while / in background #29598
I have updated to the latest available Home Assistant version.
I have cleared the cache of my browser.
I have tried a different browser to see if it is related to my browser.
I have tried reproducing the issue in safe mode to rule out problems with unsupported custom resources.
Describe the issue you are experiencing
The analog display runs too fast. The longer the page is not completely refreshed, the greater the advance. Both the digital and analog clocks use the same sensor. It seems to get worse when the page is running in the background. Browser: Chrome 145.0.7632.46 (Official Build) (64-bit)
Same behavior in Firefox 147.0.3 (64-bit)
As the code uses CSS animations I expect that the issues is they are running fast. Perhaps just like swiss railway clocks, the anolog clock could use a stop to go action and reset/calibrate every minute to make sure that it the animations are not running fast/slow. But in the swiss railway clocks the minute hand sticks and then advances, but with the anolg clock everything is smooth. However, a regular calibration point, say every minute, would likely help.
There hasn't been any activity on this issue recently. Due to the high number of incoming GitHub notifications, we have to clean some of the old issues, as many of them have already been resolved with the latest updates.
Please make sure to update to the latest Home Assistant version and check if that solves the issue. Let us know if that works for you by adding a comment 👍
This issue has now been marked as stale and will be closed if no further activity occurs. Thank you for your contributions.
There hasn't been any activity on this issue recently. Due to the high number of incoming GitHub notifications, we have to clean some of the old issues, as many of them have already been resolved with the latest updates.
Please make sure to update to the latest Home Assistant version and check if that solves the issue. Let us know if that works for you by adding a comment 👍
This issue has now been marked as stale and will be closed if no further activity occurs. Thank you for your contributions.
changed the title [-]clock card - analog[/-][+]Analog clock card gets out of sync when page is left open for a while / in background[/+]on Sep 24, 2026
I can reproduce this on current dev. Cause: _handleVisibilityChange recalculates the negative animation-delay for each hand, but the running CSS animations keep their original start time. So the time since they started is counted twice, and the hands jump ahead by however long the card has been on the page. I measured +16s after one return to the tab and +37s after a second. Restarting the hand animations whenever the delays are recalculated fixes it in my testing. I'd like to open a PR for this.
Activity
dcapslock commentedon Mar 23, 2026
As the code uses CSS animations I expect that the issues is they are running fast. Perhaps just like swiss railway clocks, the anolog clock could use a stop to go action and reset/calibrate every minute to make sure that it the animations are not running fast/slow. But in the swiss railway clocks the minute hand sticks and then advances, but with the anolg clock everything is smooth. However, a regular calibration point, say every minute, would likely help.
github-actions commentedon Jun 21, 2026
There hasn't been any activity on this issue recently. Due to the high number of incoming GitHub notifications, we have to clean some of the old issues, as many of them have already been resolved with the latest updates.
Please make sure to update to the latest Home Assistant version and check if that solves the issue. Let us know if that works for you by adding a comment 👍
This issue has now been marked as stale and will be closed if no further activity occurs. Thank you for your contributions.
github-actions commentedon Sep 21, 2026
There hasn't been any activity on this issue recently. Due to the high number of incoming GitHub notifications, we have to clean some of the old issues, as many of them have already been resolved with the latest updates.
Please make sure to update to the latest Home Assistant version and check if that solves the issue. Let us know if that works for you by adding a comment 👍
This issue has now been marked as stale and will be closed if no further activity occurs. Thank you for your contributions.
[-]clock card - analog[/-][+]Analog clock card gets out of sync when page is left open for a while / in background[/+]shazilkhan commentedon Oct 15, 2026
I can reproduce this on current
dev. Cause:_handleVisibilityChangerecalculates the negativeanimation-delayfor each hand, but the running CSS animations keep their original start time. So the time since they started is counted twice, and the hands jump ahead by however long the card has been on the page. I measured +16s after one return to the tab and +37s after a second. Restarting the hand animations whenever the delays are recalculated fixes it in my testing. I'd like to open a PR for this.Keep analog clock hands in sync after the page becomes visible again