New Findings: What is the central question of this study? Is the proposed semi-automatic algorithm suitable for tracking the medial gastrocnemius muscle–tendon junction in ultrasound images collected during passive and active conditions? What is the main finding and its importance? The validation of a method allowing efficient tracking of the muscle–tendon junction in both passive and active conditions, in healthy as well as in pathological conditions. This method was tested in common acquisition conditions and the developed software made freely available. Abstract: Clinically relevant information can be extracted from ultrasound (US) images by tracking the displacement of the junction between muscle and tendon. This paper validated automatic methods for tracking the location of muscle–tendon junction (MTJ) between the medial gastrocnemius and the Achilles tendon during passive slow and fast stretches, and active ankle rotations while walking on a treadmill. First, an automatic algorithm based on an optical flow approach was applied on collected US images. Second, results of the automatic algorithm were evaluated and corrected using a quality measure that indicated which critical images need to be manually corrected. US images from 12 typically developed (TD) children, 12 children with spastic cerebral palsy (SCP) and eight healthy adults were analysed. Automatic and semi-automatic tracking methods were compared to manual tracking using root mean square errors (RMSE). For the automatic tracking, RMSE was less than 3.1 mm for the slow stretch and 5.2 mm for the fast stretch, the worst case being for SCP. The tracking results in the fast stretch condition were improved (especially in SCP) by using the semi-automatic approach, with an RMSE reduction of about 30%. During walking, the semi-automatic method also reduced errors, with a final RMSE of 3.6 mm. In all cases, data processing was considerably shorter using the semi-automatic method (2 min) compared to manual tracking (20 min). A quick manual correction considerably improves tracking of the MTJ during gait and allows to achieve results suitable for further analyses. The proposed algorithm is freely available.