In diamond, each carbon atom is in sp3 hybridised state and linked to four other carbon atoms tetraherally by covalent bonds. Since there is no mobile electron present, diamond is a bad conductor of heat and electricity.
In graphite each carbon atom is in sp2 hybridised state and is linked to three other carbon atoms in a hexagonal planar structure. The π -electrons are free to move throughout the entire layers, therefore graphite is a good conductor of heat and electricity.