In a numerical control system, a machine tool with an automatic tool changer is provided with an origin detector for generating an origin signal when an NC drive axis for effecting relative movement between a spindle head and a work table in an axial direction of a tool spindle is returned to a machine origin. A numerical controller is connected to the NC dirve axis, the tool changer and when operated in accordance with a numerical control program, controls them so that a series of machinings can be selectively performed on a workpiece on the work table. The numerical controller executes an emergency returning control program when a manual switch is depressed to instruct the returning of the NC drive axis to the machine origin. The numerical controller, when operated in accordance with the returning control program, controls the NC drive axis to discontinue advance movement and then to effect retraction movement and further controls the drive motor to rotate in a selected direction during the retraction movement. The selection of the rotational direction is made by reference to a memory device for storing data indicative of a tool being presently used on the tool spindle. The numerical controller further controls the tool changer in accordance with the returning control program, whereby a tool which is scheduled by the numerical control program to be used firstly, can be set up on the tool spindle to make the system ready for the subsequent restarting.