As far as shaving in Hajj is concerned, Al-Bukhari and Muslim reported that the Prophet (peace and blessings be upon him) shaved his head, and so did a group of his Companions, while others only cut their hair short. Shaving here means removing the hair of the head with a razor, et cetera, or plucking the hair out. It suffices one, however, to remove only as many as three hairs.
Most scholars hold that either shaving or cutting the hair short is obligatory, and one who fails to do so must slaughter an animal in order to atone for this omission. According to the Shafi`i School of fiqh, it is an integral part of Hajj. However, the issue of which is obligatory, shaving or cutting the hair, is controversial among jurists.
Dr. Rif`at Fawzi, professor of Shari`ah at Cairo University, states: “One should bear in mind that razors and blades are now available everywhere. So, even with you having short hair, you can use a razor or blade to shave or cut some of the remains of the hair. If the person does not shave or cut his hair short in tahallul (going out of Ihram), then he will have to offer a fidyah (penance or sacrificial animal) for not performing a wajib (obligation) of Hajj.”