I have a mains powered digital clock. It has no backup battery and the time is reset when the power comes back on. The display flashes until I set the time, but continues to advance from 00:00 so I know there has been a power cut (if I was out) and I can work out exactly when the power came back on, from how slow the clock is.
I also have the type of time switch that rotates by electric motor, with pegs to flip its internal switch. At power loss, it stops turning, and at restoration, it starts turning without being reset. So this device tells me how long the power was off for, from how slow its clock is.
From those two clocks I can also work out when the power loss occurred.