Salam Dear Anum,
Thank you for your question and for contacting Ask About Islam.
First of all, it should be realized that, when Islam came, slavery was prevalent throughout the world as an acknowledged fact of socio-economic existence.
In fact, the economy of many regions during that period depended on a system where slavery played an integral part. It would have been impractical to eradicate slavery with a command to stop it altogether.
As in the case of liquor, slavery’s prohibition could have been effected only gradually. In the matter of alcohol, it was possible to ban it altogether during the life time of the Prophet Muhammad (peace and blessings be upon him).
But slavery was so deep-rooted in the social structure of the time that it had far-reaching social and economic implications. Therefore, its abolition required a period of time far longer than the life of the Prophet. This was the reason why there was no categorical ban of slavery during his time.
Moreover, when we say that Islam is a religion for all mankind and for all times, we do not at all mean that it has once and for all laid down all the rules for all times and climes in full detail. What is meant is that Islam has laid down enough general principles and guidelines that would help solve the problems that may arise from time to time.
In the matter of slavery, Islam gave a sound basis for the freeing of slaves through voluntary enfranchisement by charting a course to a permanent resolution of the complicated problem. It also presented strict conditions that made it extremely difficult for people to enslave others.
It was not that God wanted to miraculously transmute men into angels; rather He made them men and as such He knows their potentialities and weaknesses, as well as the time necessary for them to understand and adopt an injunction that has far-reaching effects.
However, it is noteworthy that Islam was the first to initiate the emancipation movement that took the world some seven centuries to adopt and enforce.
Under the Islamic system, we see slaves exalted to the position of military commanders and leaders. When the Prophet sent out an army that consisted of the closest of the Companions — the Muhajirun (Immigrants) and the Ansar (Helpers), the acknowledged leaders of the Muslims — he entrusted Zaid, a former slave, with the generalship of the army. After the death of Zaid, the Prophet appointed Zaid’s son Osama as the commander of the army consisting of such illustrious men as Abu Bakr and `Umar, his two principal Companions.
Only in Islamic history do we find slaves being elevated to the highest positions of power, such as commanders-in-chief and kings, and indeed whole dynasties like the Mamluks of Egypt and the Slave Dynasty of India.
Thus slaves were given not only a status equal and similar to others, but were at the same time raised to the exalted positions of leading the armies of free men. In this regard the Prophet commanded the believers:
“You should listen to and obey your ruler even if he was a black Ethiopian slave whose head looks like a raisin” (Al-Bukhari)
It is noteworthy that the slavery once practiced in the Muslim world cannot be compared to the form it had assumed in the Roman Empire, for instance.
Islamic legislation subjected slave-owners to a set of precise obligations, first among which was the slave’s right to life, which in other cultures was of no significance. So under Islam, the murder of a slave was punished like that of a free man.
Above all, we should not lose sight of the fact that it was Islam that first declared the equality of all human beings, including slaves: equality in origin, in values, and in destiny. Thus it was in the Islamic Ummah that for the first time ever, slaves became brothers and sisters of their masters.
The Prophet (peace be upon him) said:
“Your servants and your slaves are your brothers. Anyone who has slaves should give them from what he eats and wears. He should not charge them with work beyond their capabilities. If you must set them to hard work, in any case, I advise you to help them” (Al-Bukhari)
Freeing a slave has always been regarded as one of the most meritorious of all acts, and many passages of the Quran require it, particularly as a means of expiation for serious faults.
Traditional legislation lays down the methods of voluntary liberation of slaves by their masters, and there were many Muslims who observed these, so as not to die and appear before God without having given full freedom to the human beings placed in their power during their earthly lives.
Slavery was never praised or encouraged in Islam. One of the Companions, `Umar ibn Al-Khattab, berated Muslims in a famous khutbah (sermon), asking them “When did you enslave people while Allah the Almighty created them free?”
This means that the Muslims from the very beginning advocated the freedom of all human beings and were against the oppression and enslavement of free people.
With regards to the hadith you quoted, the reference was to a servant or helper of the Prophet, as can be understood from the teachings and practices of Prophet Muhammad (peace and blessings be upon him). Therefore, the translation should read a “black servant,” not “slave.”
I hope this answer helps you. Please keep in touch.