A method for operating a press-in machine for pressing at least one of an electrical, electronic, mechanical and electromechanical component into a substrate, wherein the press-in machine comprises a moving unit, which comprises a receptacle for the substrate and with which the substrate can be moved in a plane, which is spanned by an x-axis and a y-axis and can be placed in a press-in position, a lower tool, which comes to rest against the underside of the substrate before or during the press-in, an upper tool, which can be moved against one or more components in order to press the one or more components along a z-axis toward the substrate, and a sensor for detecting at least one reference mark present on the substrate, the method comprising the steps of:
- a. detecting at least one reference mark present on the substrate by the sensor, and
- b. placing the moving unit in the press-in position depending on the detected reference mark between the lower tool and the upper tool.