A method for calibrating the geometric errors of a machine tool with a head able to move in the workload of the machine, which uses a position gauge being arranged in the head and a calibration tool with reference patterns being arranged in the work volume of the machine, the spatial position of the reference patterns being determined by means of the position gauge to automatically correct the geometric errors of the machine tool, characterised in that the method comprises the steps of: • using first reference markers being arranged in the calibration tool and using second reference markers being arranged in the machine tool; • determining the relative position between the first reference markers and the reference patterns , and the relative position between the second reference markers and the position gauge ; • using vision means comprising a movable camera or more than one fixed camera for capturing at least one image of the work volume of the machine, the first reference markers of the calibration tool and the second reference markers being observable in the work volume of the machine; • determining a spatial position for each one of the first and second reference markers in the work volume of the machine, using at least one image captured by the vision means ; • determining the approximate spatial positions of the reference patterns of the calibration tool according to the spatial position of each one of the first and second reference markers determined in the preceding step; • automatically moving the head with the position gauge to one of the reference patterns of the calibration tool according to the approximate spatial positions of the reference patterns determined in the preceding step; • determining the actual spatial positions of the reference patterns by means of the position gauge , • automatically correcting the geometric errors of the machine tool by processing the information of the approximate and actual spatial positions of the reference patterns . • using first reference markers being arranged in the calibration tool and using second reference markers being arranged in the machine tool; • determining the relative position between the first reference markers and the reference patterns , and the relative position between the second reference markers and the position gauge ; • using vision means comprising a movable camera or more than one fixed camera for capturing at least one image of the work volume of the machine, the first reference markers of the calibration tool and the second reference markers being observable in the work volume of the machine; • determining a spatial position for each one of the first and second reference markers in the work volume of the machine, using at least one image captured by the vision means ; • determining the approximate spatial positions of the reference patterns of the calibration tool according to the spatial position of each one of the first and second reference markers determined in the preceding step; • automatically moving the head with the position gauge to one of the reference patterns of the calibration tool according to the approximate spatial positions of the reference patterns determined in the preceding step; • determining the actual spatial positions of the reference patterns by means of the position gauge , • automatically correcting the geometric errors of the machine tool by processing the information of the approximate and actual spatial positions of the reference patterns . <EOS>