A microscope device comprising: an objective; an actuator for adjustment of a distance between the objective and a sampleholding substrate (2, 3) in a focusing direction z during a focusing action to reach and hold a desired focus position; an absolute z-position detector for measuring a z-position of the actuator in the focusing direction; an autofocus light source; a first optical arrangement (12, 13) for generating a focused spot of autofocus light from the light source in the backfocal plane of the objective at a position offset from the optical axis of the objective by a lateral offset distance ( d), such that the objective generates a collimated incoming beam of autofocus light, which is directed at an oblique angle (β) relative to the optical axis of the objective onto the substrate; a second optical arrangement (13, 16) for generating collimated outgoing beams (34, 35) of autofocus light from the collimated incoming beam as reflected by a substrate surface (4, 5) through the objective and directing the collimated outgoing beam onto a sensor-array comprising a plurality of sensor elements; a relative z-position detector comprising the sensor-array configured to detect the wandering position of the outgoing collimated autofocus light beam (34,35) on the sensor-array during the focusing action, the wandering position reflecting a change in the distance between the objective and the reflecting substrate surface (4,5) in the z-direction; and a central control unit (8, 10) configured to control the actuator based on signals from the absolute z-position detector and the relative z-position detector, wherein the signal of the relative z-position detector is used to dynamically recalibrate the absolute z-position detector during the focusing action. an objective; an actuator for adjustment of a distance between the objective and a sampleholding substrate (2, 3) in a focusing direction z during a focusing action to reach and hold a desired focus position; an absolute z-position detector for measuring a z-position of the actuator in the focusing direction; an autofocus light source; a first optical arrangement (12, 13) for generating a focused spot of autofocus light from the light source in the backfocal plane of the objective at a position offset from the optical axis of the objective by a lateral offset distance ( d), such that the objective generates a collimated incoming beam of autofocus light, which is directed at an oblique angle (β) relative to the optical axis of the objective onto the substrate; a second optical arrangement (13, 16) for generating collimated outgoing beams (34, 35) of autofocus light from the collimated incoming beam as reflected by a substrate surface (4, 5) through the objective and directing the collimated outgoing beam onto a sensor-array comprising a plurality of sensor elements; a relative z-position detector comprising the sensor-array configured to detect the wandering position of the outgoing collimated autofocus light beam (34,35) on the sensor-array during the focusing action, the wandering position reflecting a change in the distance between the objective and the reflecting substrate surface (4,5) in the z-direction; and a central control unit (8, 10) configured to control the actuator based on signals from the absolute z-position detector and the relative z-position detector, wherein the signal of the relative z-position detector is used to dynamically recalibrate the absolute z-position detector during the focusing action.