Caution: Translations of Quran and Ḥadīth may lead to possible misapplications and misinterpretations. This site is intended for students of sacred knowledge that are proficient in comprehending classical Arabic and have a strong foundation in Islamic sciences. Also note that religious injunctions rely on several aspects beyond what one may glean through reading individual aḥādīth.
quran:42:49

To Allah belongs the dominion of the heavens and the earth; He creates what he wills. He gives to whom He wills female ˹children˺, and He gives to whom He wills males.  

To God belongs the kingdom of the heavens and the earth. He creates whatever He will; He gives to whomever He will, in the way of children, females, and He gives to whomever He will males.
القرآن:٤٢:٤٩

لِلَّهِ مُلْكُ السَّمَاوَاتِ وَالْأَرْضِ ۚ يَخْلُقُ مَا يَشَاءُ ۚ يَهَبُ لِمَنْ يَشَاءُ إِنَاثًا وَيَهَبُ لِمَنْ يَشَاءُ الذُّكُورَ  

{لله ملك السماوات والأرض يخلق ما يشاء يهب لمن يشاء} من الأولاد {إناثاً ويهب لمن يشاء الذكور}.