Ectopia cordis is a congenital malformation in which the heart is abnormally located either partially or totally outside of the thorax.