Surah Ash-Shuraa 42:50
أَوْ يُزَوِّجُهُمْ ذُكْرَانًا وَإِنَـٰثًا ۖ وَيَجْعَلُ مَن يَشَآءُ عَقِيمًا ۚ إِنَّهُۥ عَلِيمٌ قَدِيرٌ
Or He makes them [both] males and females, and He renders whom He wills barren. Indeed, He is Knowing and Competent.
Translation: Saheeh International
Tafsir
Or He combines them that is to say or He makes them males and females; and He makes whomever He will infertile such that she is unable to conceive or he cannot have a child. Surely He is Knower of what He creates Powerful in bringing about whatever He will.
Excerpt from Tafsir al-Jalalayn, commentary on 42:50, via Quran.com. The reader has the full commentary and 9 more tafsirs.