A medical device for carrying out at least one medical function, comprising at least one element that can be at least partially inserted into a body tissue of a user and further comprising at least one housing that can be placed on a skin surface of the user. The housing has a multipart design and comprises at least one functional component. The functional component can be connected to the insertable element. The housing further comprises at least one protective component. The protective component is designed to at least partially enclose the functional component. The protective component can be connected to the functional component, particularly after insertion of the insertable element.