The microdosimetric variance-covariance method was used to study the stray radiation fields from the photon therapy facility at the Technical University of Denmark and the scanned proton therapy beam at the Skandion Clinic in Uppsala, Sweden. Two TEPCs were used to determine the absorbed dose, the dose-average lineal energy, the dose-average quality factor and the dose equivalent. The neutron component measured by the detectors at the proton beam was studied through Monte Carlo simulations using the code MCNP6. In the photon beam the stray absorbed dose ranged between 0.3 and 2.4 μGy per monitor unit, and the dose equivalent between 0.4 and 9 μSv per monitor unit, depending on beam energy and measurement position. In the proton beam the stray absorbed dose ranged between 3 and 135 μGy per prescribed Gy, depending on detector position and primary proton energy.