The invention relates to a stroke frequency regulating apparatus of an oil pumping machine, which belongs to the technical field of oil exploitation and extraction equipment and is characterized in that three synchronizing pinions (16), (12) and (11) and three variable speed pinions (15), (13) and (8) are arranged on an input shaft (9); three synchronizing gearwheels (17), (21) and (22) and three variable speed gearwheels (19), (20) and (23) are arranged on an output shaft (18); three pairs of synchronizing gears keep engaged all the time; and when a shifting handle (14) is screwed and a fork head (4) of a shifting fork is pressed, the fork head can be clamped in fork pockets on the three variable speed pinions (15), (13) and (8) on the input shaft (9), so that the variable speed pinions can be toggled to move axially and realize shift operation. The regulating apparatus has simple and compact structure and convenient manufacture and can fully adapt to shift demands under various conditions, and when the stroke frequency regulating apparatus is arranged on the oil pumping machine, the shift quality can be improved, and the shift time can be reduced.