Device for connecting a component to a substrate, with a chamber divisible into at least two parts, wherein a stamp (11, 111) is provided on a first part (1), and a counter-stamp (31) is provided on a second part (3), wherein the first part (1) has a wall with an edge which can be brought into contact with an opposite edge of a wall of the second part (3) in order to close the chamber, wherein the counter-stamp (31) can be loaded with starting materials in an open state of the chamber, and in a
closed state of the chamber, pressure can be exerted on the starting materials provided between the stamp (11, 111) and the counter-stamp (31) via the stamp (11), wherein In the
closed state, the first part (1) and the second part (3) can be locked together by means of a positive
locking mechanism, so that opening of the chamber by separation of the first part (1) from the second part (3) is prevented, characterized by the fact that Each edge has a recess (131) and / or a projection (137; 39) with a hole (133a, 133b; 391) which can be brought into contact with a projection (39; 137) and / or a recess (131) of the opposite edge, wherein a cross-section of the hole (133a, 133b) of the projection (137a, 137b) of the wall of the first part (1) in a brought-in state at least partially overlaps with a cross-section of the hole (391) of the projection (39) of the wall of the second part (3), and the positive locking can be achieved by means of a pin (135) guided through both holes (133a, 133b; 391).