The encoder has a cylindrical rotor (1) the surface of which faces the teeth and teeth gaps on the magnetically conductive part (4) of a stator (5) provided with sensors (2, 3). The sensors detect flux changes created by the movement of the rotor. The rotor surface contains north and south pole faces (9) extending in the axial direction over the rotor and in the direction of rotation for equal distances and are of alternating polarity. At least two sensors are positioned at different points of a tooth or on two different teeth.