Source modelling in magnetoencephalography (MEG) requires precise co-registration of the sensor array and the anatomical structure of the measured individual's head. In conventional MEG, the positions and orientations of the sensors relative to each other are fixed and known beforehand, requiring only localization of the head relative to the sensor array. Since the sensors in on-scalp MEG are positioned on the scalp, locations of the individual sensors depend on the subject's head shape and size. The positions and orientations of on-scalp sensors must therefore be measured at every recording. This can be achieved by inverting conventional head localization, localizing the sensors relative to the head - rather than the other way around. In this study we present a practical method for localizing sensors using magnetic dipole-like coils attached to the subject's head. We implement and evaluate the method in a set of on-scalp MEG recordings using a 7-channel on-scalp MEG system based on high critical temperature superconducting quantum interference devices (high-Tc SQUIDs). The method allows individually localizing the sensor positions, orientations, and responsivities with high accuracy using only a short averaging time (≤ 2 mm, < 3° and < 3%, respectively, with 1-s averaging), enabling continuous sensor localization. Calibrating and jointly localizing the sensor array can further improve the accuracy of position and orientation (< 1 mm and < 1°, respectively, with 1-s coil recordings). We demonstrate source localization of on-scalp recorded somatosensory evoked activity based on co-registration with our method. Equivalent current dipole fits of the evoked responses corresponded well (within 4.2 mm) with those based on a commercial, whole-head MEG system.