This paper deals with the numerical simulation of heat transfer and entropy generation in a 2D square enclosure for convective melting. A thermal lattice Boltzmann method (TLBM) is used to handle the study, which has been conducted for Prandtl numbers from 0.02 to 70 at Rayleigh numbers of 10 4 and 10 5. The results are presented in terms of the total entropy generation, average Bejan number and average Nusselt number. Within the range considered for the key parameters, the entropy generation is found to be controlled by the heat transfer loss for low Prandtl numbers. However, for the large Prandtl numbers, its variation is dominated by shearing losses. Moreover, the presence of the latent heat state decreases the overall thermodynamic losses while increasing the quantity of heat transferred.