The invention relates to a numerical control machine tool, and provides a numerical control vertical and horizontal compound machine. The numerical control vertical and horizontal compound machine comprises a machine frame, a work table, a fixing seat, a cross slide table, a first driving unit, a horizontal main shaft box, a vertical main shaft box, a horizontal tool magazine and a vertical tool magazine, wherein the the horizontal main shaft box comprises a stand column, a power head, a main shaft motor, a sliding table, a supporting base, a transverse rod, a second driving unit and a third driving unit, the stand column is an n-shaped stand column provided with a hollow groove, the sliding table is arranged on the hollow groove of the stand column in an up-down sliding mode through the second driving unit, the transverse rod is arranged on the upper surface of the sliding table in a horizontal sliding mode through the third driving unit, the upper surface of the transverse rod perpendicularly intersects with the vertical plane of the hollow groove of the stand column, the main shaft motor is arranged on the supporting base, and an output shaft of the main shaft motor is connectedwith and drives a main shaft of the power head to rotate to machine a to-be-machined workpiece on the work table. The numerical control vertical and horizontal compound machine solves the problems that an existing vertical and horizontal combined machining center is large in occupied space and high in manufacturing cost.