Residential homes and light commercial buildings usually require substantial heat and electricity simultaneously. A combined heat and power system enables more efficient and environmentally friendly energy usage than that achieved when heat and electricity are produced in separate processes. However, due to financial and space constraints, residential and light commercial buildings often limit the use of traditional large-scale industrial equipment. Here we develop a micro–combined heat and power system powered by an opposed-piston engine to simultaneously generate electricity and provide heat to residential homes or light commercial buildings. The developed prototype attains the maximum AC electrical efficiency of 35.2%. The electrical efficiency breaks the typical upper boundary of 30% for micro–combined heat and power systems using small internal combustion engines (i.e., <10 kW). Moreover, the developed prototype enables maximum combined electrical and thermal efficiencies greater than 93%. The prototype is optimally designed for natural gas but can also run renewable biogas and hydrogen, supporting the transition from current conventional fossil fuels to zero carbon emissions in the future. The analysis of the unit’s decarbonization and cost-saving potential indicate that, except for specific locations, the developed prototype might excel in achieving decarbonization and cost savings primarily in US northern and middle climate zones.