An endoscope according to the invention comprises an endoscope shaft (3), which has a cylindrical shaft tube (4), and an endoscope head (2), which is arranged at a proximal end of the endoscope shaft (3) and, in a distal end region (11), has a cylindrical interior (13) with a peripheral groove (15), wherein the shaft tube (4) is inserted into the cylindrical interior (13) and folded into the peripheral groove (15). According to the invention, the groove (15) is not rotationally symmetrical. The invention further relates to an endoscope head and to a method for producing an endoscope.