A method produces a housing with at least one hermetically sealed receiving space for an electronic component, the receiving space including at least a part of the interior of the housing. In the method, a hollow body made of glass and having at least one opening is produced/provided, at least one electronic device is introduced through the at least one opening, and the receiving space is hermetically sealed by melting the housing, or the at least one opening is sealed by laser radiation. A device has an at least partially hermetically sealed housing made of silicon, particularly a housing produced according to the above-mentioned method.