A method for manufacturing a sensor in which a sensor element, which comprises at least a first housing, is at least partially encapsulation-molded in an encapsulation-molding process. As a result of the encapsulation-molding process a sensor housing is formed. The sensor element is mechanically connected to a support element and/or accommodated by the support element, after which the sensor element and the support element are encapsulation-molded in a common encapsulation-molding process for forming the sensor housing.