To investigate the effect of surface roughness on the heat transfer mechanism, a molecular dynamics model of heat transfer between solid and liquid interfaces was established in this paper. The temperature distribution, heat flux, thermal resistance, and number density distribution of water molecules in the interface are calculated and discussed systematically. The effects of energy parameters between solid and liquid, and the roughness level of the wall on the heat transfer performance were analyzed. The results show that as the energy parameter rises from 0.413 to 1.651 kcal/mol, the heat flux increases from 1.5 x 109 to 3.2 x 109 Wm-2, and the thermal resistance at the cold and hot ends of the solid-liquid interface demonstrates a decreasing trend from 18.75 x 10-9 to 2.50 x 10-9 Km2<middle dot>W-1. It indicates that the interaction between solid and liquid is enhanced, and more water molecules gather near the solid-liquid interface, which promotes energy transfer and thus strengthens the heat transfer between solid and liquid. As the depth of surface roughness varies from 1a to 2.5a, the static contact angle of droplets decreases from 69.06 degrees +/- 0.28 degrees to 49.98 degrees +/- 0.44 degrees, slightly enhancing the hydrophilicity of the rough wall structure. Thus, compared with the smooth wall, the rough wall structure enables more water molecules to come into contact with the wall, thereby increasing the heat transfer area and consequently enhancing the heat flux and reducing the thermal resistance. With the increase of wall roughness, the cold (hot) thermal resistance further decreases from 19.2 (19.7) x 10-9 to 4.9 (5.0) x 10-9 Km2<middle dot>W-1.