Unfortunately, Islam has some serious moral issues, and atheists do criticize Islam on the basis. 

In order to defend Islam against this criticism, Islamists claim that atheists have no rights to criticize Islam as atheism itself has no moral foundation. 

For example, the MuslimSkeptic Website, which belongs to famous Islamic apologist Daniel Haqiqatjou, writes (link):  

Atheism Has No Morality: The overwhelming majority of atheist “criticism” against Islam and religion in general are moral claims. Yet to an intelligent person this does not make sense. How do people without any moral foundation have the audacity to make moral arguments in the first place? In short there is “objective morality” and then there is “subjective morality.” You see, atheists do not have any objective morality in the first place. What atheism can only do is create subjective morality. Subjective = opinion, whereas objective = fact (there is no 3rd one).e.g: “Red is the best color” is subjective, but “2+2=4” is objective. In other words, atheists are criticizing Islam based on their own subjective personal opinions. They might as well say, “I hate Islam because Muslims like the color green, but my favorite color is blue,” and it be no different than the garbage they say currently.

Response: Moral principles (the moral foundation) are based on the "humanity" within us

The humanity within us is enough to guide us on what is right and what is wrong.

The intrinsic qualities of humanity, such as empathy, compassion and sense of justice etc., are sufficient to help us distinguish right from wrong. 

Our inherent humanity itself provides a universal moral compass that transcends individual opinions or beliefs. Moral principles are not comparable to subjective opinions or tastes, as they are rooted in fundamental human values and are objectively discernible. Thus:

(1) Moral principles consist of two aspects:

  • The "moral principles" (the basic framework/moral foundation) are "objective" in nature. 
  • While the "application" of these moral principles to different issues in our lives is "subjective." 

For example, the book of law is same in a country. But different judges may come to different decision about daily life issues while using the same book of laws. 

(2) Changes in Morality:

  • The objective part of morality (i.e., moral principles) never changes.
  • However, the subjective part of morality (i.e., the application of these moral principles) can change with time and knowledge. Reforms are made only in this way. 

(3) Internal vs. External Factors:

  • The objective part of morality is entirely internal (i.e., based on inherent humanity within us).
  • The subjective part of morality (i.e., the application) can also be influenced by external factors. As individuals mature, their moral compass is no longer solely determined by innate empathy, but enlightened self-interest, upbringing, and societal pressures also become increasingly influential in shaping an adult's moral values. While empathy remains a vital aspect of moral development throughout a person's life, its significance may wane as other factors come into play.

(4) Self-interest is also innate, and it may play as an opposite force to Humanity:

  • Just like humanity, self-interest (like greed, lust for power/money etc.) is a natural part of us.
  • Self-Interest may play as an opposite force to Humanity. People may ignore humanity, and do bad deeds for their self-Interests.

(5) External Factors may be negative or positive:

  • Factors like upbringing and societal pressures etc. are not always negative.
  • They may be negative, but may also be positive. If the upbringing is positive, then it helps humanity. But if the upbringing is negative, then it plays as a counter force to humanity.

Good upbringing refines character but doesn't determine its origin. The same holds true for bad upbringing.

For instance, Buddha was raised within Hinduism's caste system. Despite this upbringing, he maintained his humanity and questioned the teachings of the caste system. His innate sense of morality led him to reject these teachings and eventually create a new religion free from such injustices.

(6) And then there are some innate emotions like "ANGER" and "LOVE" etc. 

Innate emotions like anger has a potential to go in the negative direction and suppress the feeling of humanity. But anger against wrong things may also be beneficial and it may encourage people to do the right things on a greater scale.

Yes, innate humanity within Muslims also clearly guides them on matters of right and wrong

For instance, consider the issue of killing an innocent Muslim only for leaving Islam, known as apostasy.

Please be assure that innate humanity in every Muslim unequivocally recognizes this as a double standard and an injustice, as Islam expects non-Muslims to convert but prohibits the reverse.

However, radical Muslims manage to suppress this innate sense of justice due to the external influences of religious upbringing and indoctrination. This indoctrination instills a heightened moral value in their minds, prioritizing Allah's commands over innate human morality. Thus, they perceive obedience to Allah's commands as morally superior to following their innate sense of justice.

But in ex-Muslims, the voice of innate humanity superseded the effects of religious upbringing and brainwashing. Thus, they rebelled against the Islamic system.

Similarly, be assure that every religious Hindu can recognize the injustice of the caste system through their innate humanity. Yet, the external factors of upbringing and religious indoctrination instill a belief that religious commands hold supreme moral authority, overriding their innate sense of justice.

In the case of Buddha, his innate humanity prevailed over religious indoctrination, leading him to rebel against the caste system.

Islamists analogy of personal preferences to be a part of morals is WRONG and only a Deception

Furthermore, the analogy drawn between personal preferences (by Daniel Haqiqatjou's website), such as a preference for the color blue, and moral judgments is misguided. Moral principles are not comparable to subjective opinions or tastes, as they are rooted in fundamental human values and are objectively discernible. The mistreatment of slaves in Islam cannot be dismissed as a matter of personal taste or opinion; rather, it is a clear violation of basic human rights and dignity. Even if some Muslims may personally dislike the color green or have a fondness for blue, this does not detract from the fact that the injustices perpetrated under Islamic slavery are morally repugnant and demand condemnation.

 

The Origin of Humanity/Morality lies in our Hormones:

Our physiology has EVOLVED to release hormones that promote feelings of happiness and well-being when we engage in positive social interactions, such as showing love, kindness, or empathy towards others. This suggests that morality may have an innate component, as demonstrated by a scientific study which highlights the biological basis of moral behaviour:

https://www.sciencedirect.com/science/article/pii/B9780124201903000454

Abstract

Is there an innate moral sense? Scientific evidence, from child development, linguistics, and behavioral economics to neuroscience, moral psychology, and primatology reveals universal drives that constitute a biologically prepared moral architecture within human nature. This innate moral sense is akin to the innate predisposition for smell or language and suggests human beings are born with the prototypes of a sense that fosters anxiety when they witness others in distress and, similarly, promotes positive feelings when that distress is alleviated. Incorporating the concept of an innate moral sense into our models of social and political life would improve ethical analysis.

Nobody needs to instruct a baby on how to love their mother; it comes naturally thanks to hormonal influences.

Skin-to-skin contact between a newborn and their mother shortly after delivery is crucial and emotionally charged for both parties. Your touch and voice provide comfort and security for your baby, and this interaction triggers the release of oxytocin in your body.

Notably, childbirth and breastfeeding lead to a significant increase in oxytocin levels in women, promoting maternal bonding and nurturing behaviors.

Oxytocin, often referred to as the "love hormone," plays a crucial role in fostering attachment between parents and their offspring. While it was initially believed that only mothers experienced a surge in oxytocin levels during childbirth and breastfeeding, research has shown that fathers also exhibit similar hormonal changes when they engage in activities that promote bonding with their children.

Studies have revealed that emotionally invested fathers display increased levels of prolactin, a hormone typically associated with breastfeeding and sexual satisfaction, and vasopressin, a hormone linked to bonding and stress response in mothers. These findings suggest that fathers who actively participate in parenting experiences can experience hormonal changes akin to those of mothers.

However, the extent to which these hormonal changes occur depends on the level of proximity and interaction between the father and child. For instance, when a child sleeps with their parents, the father's recognition and response to the baby's cries, and playful interactions between the two, all contribute to strengthening their bond. In contrast, when there is a lack of physical closeness, the fatherhood effect diminishes.

As individuals mature, their moral compass is no longer solely determined by innate factors. Empathy, enlightened self-interest, and societal pressures become increasingly influential in shaping an adult's moral values. While empathy remains a vital aspect of moral development throughout a person's life, its significance wanes somewhat as other factors come into play.

In contrast, infants rely heavily on instinctual behaviours such as empathy and trust in their caregivers, which significantly impact their early moral formation. As the child grows and interacts more with society, external influences progressively shape their moral code. Ultimately, the interplay between innate tendencies and environmental factors contributes to the complex and dynamic nature of human morality.

 

Religions have neither objective nor subjective Morality, but only a "Moral Code":

Although Islamists blame atheists of having no objective morality, but the truth is, it is the religion that itself has neither objective nor subjective morality. 

Islam doesn't provide a moral or ethical framework that justifies why an act is considered right or wrong. Rather, it provides a "moral code" similar to that of the Mafia, the "Yakuza".

The moral code of Islam forces its members to follow the orders of their gang leader [Muhammad/Allah/Caliphate/Amir], just like the Mafia members have to follow the orders of their Godfather, and the Yakuza members follow the orders of their Kumicho.

For example, the webstie of Islamic apologists Daniel Haqiqatjou writes (source):

What Is Morality: Now morality, just like heaven, is a religious concept. For us, the definition of good (right; justice) is simply obedience to Allah. And the definition of bad (wrong; injustice; evil) is disobedience to Allah. This never changes, they are objective, and based on the wisdom of Allah ... Very simple rules and definitions. We think actions like murder, stealing, rape etc., are wrong simply because Allah forbid these things. By committing these actions we are disobeying Allah and that is why these actions are evil.

This means, whatever acts Allah/Muhammad prohibits, e.g., murder, rape, stealing, etc., are Haram/wrong/evil [if committed against Muslims]. However, the same acts are Halal/good/right [if committed against non-Muslims].

One wonder if Allah/Muhammad forbid such acts because they were wrong? Or are they wrong because He forbade them?

Steven Weinberg famously said: “With or without religion, you would have good people doing good things and evil people doing evil things. But for good people to do evil things, that takes religion.”

 

An Example of "Islamic Moral Code":

Following acts are CRIMES of Islamic Slavery against HUMANITY, based upon morality.

But Islamists falsely give it the name of "objective morality", and act upon it, without realizing its criminal nature. Allah says about salvey and sex slavery: 

  • It is okay to rape captive women and even minor girls (although they were innocent and had no role in the war). 
  • It is okay to turn captives (including small children) into slaves for their entire life.
  • It is okay that coming generations of slave parents are also born automatically as slaves (i.e. the evil of Slavery by Birth in Islam).
  • It is okay to separate a baby of 6 months (who has two teeth) from his/her slave parents and sell him/her in the Islamic Bazaars of Slavery. 
  • It is okay for an owner to rape his slave girls. And after fulfilling his lust, it was ok for him to hand her over to his brother or slave. And once all his brothers and slaves have raped her one by one (in Shia Muta Type "TEMPORARY Sexual Relationship), then she could be sold to 2nd master in the Islamic Bazaar of Slavery. And it was ok for the 2nd 2nd to rape her, and then sell her to the 3rd master...
  • It is okay for an owner to snatch away the wife of his slave, and then rape her, and then return her to his slave.
  • It is okay to prohibit slave women from taking Hijab. 
  • It is okay that slave women are compelled to move in public with naked breasts ... (Please read all these Sharia Rulings about Slaves here

Muslims (especially radical Muslims) can commit all types of other crimes too (like killing innocent people for leaving Islam), attacking and killing non-Muslim nations in the name of Jihad etc. while they consider it to be an "objective morality". 

 

Buddha didn't need any Divine Objective Morality; instead, he created his own system of morality:

Buddha didn't believe in any gods, and he didn't claim to be a prophet. He relied solely on his mind and rational thinking to develop his teachings. The humanity within him was sufficient to guide him toward what is good.

Islamic Preachers are mistaken when they claim that atheists cannot have any moral foundation without a god or religion. They forget that humanity transcends all religions and gods (including Allah).

Now, let's rephrase the question:

  • Do Muslim Preachers believe that Buddha had morals? 
  • Do you deny that Buddha was able to create a whole new system of morality using rational human thinking (i.e., freethinking) guided by the humanity within him? He didn't need any angel to bring any revelation from any god for this new system of morality.

Indeed, humanity and empathy provide the foundation upon which we build the entire system of morality.

 

Ashoka the Great abolished Slave Trade and Bazaars of Slavery, but Muslim Rulers didn't:

Ashoka the Great was the follower of Buddha. In the name of Humanity, he banned slave trade from entire India, and abolished all Bazaas of Slavery (link). 

But Muslims conquered India after 800 years, and they again reinstalled slave trade and Bazaars of slavery in India. 

Actually not only in India, but in entire Islamic world, slave-trade and bazaars of slavery flourished greatly under the Islamic Caliphate throughout 1400 years of the history of Islam. The slave trade was at its peak in the Islamic caliphate, and slave traders all over the world came to Islamic bazaars of slavery.

Even after Ashoka, the Buddhists kept on trying to bring reforms, in order to end slavery. And through Human thinking, the latter coming Buddhist government in the 13th century abolished slavery completely by replacing it with the system of Serfdom (link). Again, this is that achievement, which Muhammad missed by miles during his era, as well as Muslims of the next 1400 years.

 

Muslim Tactic: CONFUSING people, so they don't dare to criticize the evils of Islamic moral code

Modern Islamists (like Mohammad Hijab etc.) use different tactics so that normal people become CONFUSED and don't dare to start questioning the evils of Islamic moral code against humanity. These tactics are:

  • Quoting/Misquoting atheist philosophers (like Nietzsche, John Stewart Mill, Jeremy Bentham etc.), or using terms like Utilitarianism, Hedonism, The Harm Principle etc. Normal people never heard these names and terminologies, thus they become confused and stop criticizing the evils of Islam. 
  • Moreover, they tell normal people that they are not "qualified" enough to criticize Islam. They should first get a PhD degree in philosophy and Islam, and only then do they get the right to differ from Islamic morality. 

Response:

The answer is "NO":

  • We don't need to read or follow the teachings of any atheist philosopher. We read them only to deepen our knowledge, but we don't have a "Master-Slave Morality" relationship with these atheist philosophers like Muslims have with Muhammad. 
  • Moreover, all such things like Humanity, Empathy, Utilitarianism, Hedonism, the Harm Principle etc., there is hardly any difference among them, and one comes to the same final results in one way or another. 
  • And we don't need a PhD in philosophy first to criticize the wrong things in Islam. 

And the "humanity" within us is fully enough to guide us:

  • that Islamic moral code is criminal when it allows raping innocent captive women and even small girls, although they have no role in wars, or when it practices "Slavery by Birth", or when it snatches away a baby with two teeth (i.e. 6 months old) and sell the baby in the Islamic Bazaars of slavery .... 
  • that Islamic moral code is criminal when it kills people for leaving Islam. 
  • that Islamic moral code is criminal when it incites hatred against non-Muslims, and incites Jihadists to attack non-Muslim states and impose Islamic Sharia there forcefully. 

Remember, Buddha didn't know any atheist philosophers or terms like Utilitarianism, Hedonism, the Harm principle etc., but humanity within him was fully enough to guide him towards the good. 

Remember, we ex-Muslims also didn't know any atheist philosophers when we were Muslims. Still, the humanity within us was also telling us clearly at that time (when we were Muslims) that Islamic moral code regarding poor slaves and apostasy and hating non-Muslims was wrong. Yes, we were also brainwashed during our whole religious life as Muslims that Islamic morals are from Allah and thus they cannot be challenged. Still, humanity within us kept on challenging this religious brainwashing and won this war in the end. 

Even moderate/progressive Muslims feel today that Slavery is wrong, killing people for simply leaving Islam is wrong, It is due to the presence of humanity in them. Therefore, they try to CHANGE these Islamic Rulings in the name of Reforming Islam. (Note: It was the same with Buddha too, who didn't end the caste system altogether, but reformed it by claiming that all four castes are equal, and preference is only based upon Karma). 

The lesson is, that you neither need a PhD degree first to enter Islam nor to criticize Islam nor to leave Islam.