We propose a new type of experiment that compares the frequency of a clock (an ultrastable optical cavity in this case) at time t to its own frequency some time t-T earlier, by "storing" the output signal (photons) in a fiber delay line. In ultralight oscillating dark matter (DM) models, such an experiment is sensitive to coupling of DM to the standard model fields, through oscillations of the cavity and fiber lengths and of the fiber refractive index. Additionally, the sensitivity is significantly enhanced around the mechanical resonances of the cavity. We present experimental results of such an experiment and report no evidence of DM for masses in the [4.1 × 10 −11 , 8.3 × 10 −10 ] eV region. In addition, we improve constraints on the involved coupling constants by one order of magnitude in a standard galactic DM model, at the mass corresponding to the resonant frequency of our cavity. Furthermore, in the model of relaxion DM, we improve on existing constraints over the whole DM mass range by about one order of magnitude, and up to 6 orders of magnitude at resonance.