The contact-type linear encoder-like capacitive displacement sensor (CLECDiS) is an improved comb-type displacement sensor for high resolution. The sensor displays significantly improved sensitivity without a reduction in the measurable range. This improvement is achieved by maximizing the capacitance variation in response to displacement by reducing the single electrode size, increasing the number of electrodes, and reducing the gap with a contact mechanism in the comb-type sensor. However, owing to the improved sensitivity of the sensor, its output signal is affected considerably by certain geometrical non-idealities such as fabrication errors, which are negligible in traditional capacitive displacement sensors with a single electrode and a relatively large gap. Although the effect of such non-idealities can be minimized or compensated by employing an appropriate filter or differential operation, these solutions cannot deal successfully with effects due to the surface profile of the sensor. During operating of the sensor, this profile causes gap variation, which in turn causes drift in the output signal. This drift is difficult to compensate because it depends on the displacement and the low-frequency component caused by the actual gap variation. In this study, a compensation method is presented to minimize the effects due to non-idealities of the surface geometry of the sensor using electrode configuration. Furthermore, the effect of non-idealities on the capacitance of the sensor is analyzed. The analyzed results are used to present a configuration method based on a widely used differential operation. Finally, the method is tested and compared for sensors based on the normal and proposed configurations. (c) 2012 Elsevier B.V. All rights reserved.