An abnormality in the synthesis or catabolism of heme. Heme is composed of ferrous iron and protoporphyrin IX and is an essential molecule as the prosthetic group of hemeproteins such as hemoglobin, myoglobin, mitochondrial and microsomal cytochromes. The phenotype is Abnormal circulating porphyrin concentration (HP_0010472, a Human Phenotype Ontology term).