A novel method is proposed for rail fastener detection based on millimetre‐wave (mmWave) radar, mmWave radar fastener counter (MMW‐FC), which can accurately detect and record the fasteners in real‐time as the train traverses its route. Under circumstances where GNSS signals remain unavailable for prolonged durations, precise train localisation can be accomplished by correlating the number of fasteners derived from this method with the corresponding track map. Initially, MMW‐FC utilises fast Fourier transform and adaptive beamforming to focus the energy reflected from fasteners. Subsequently, it applies an adaptive template‐matching algorithm to detect each fastener. Furthermore, by leveraging known fastener spacing and the average time for trains to pass adjacent fasteners, the Kalman filter can execute precise speed tracking, used as a speed reference when adjusting the matching template adaptively. The experimental results indicate that the proposed method can precisely count the fasteners the train encounters in diverse road and speed conditions. The fastener counter maintains the Counting Error less than 0.067%, the speed error stays below 1.8 km/h, and the maximum values of the mean absolute error and root mean square error for speed are 0.7337 and 0.9584 km/h, respectively.