If you read Deuteronomy 23:1-8 and are NOT a Biblical savant you probably scratched your head and thought… wut? Seriously. What does this even mean? I’ll put the whole section in here for context:
23:1 A man with crushed or severed genitals may not enter the assembly of the Lord. 2 A person of illegitimate birth may not enter the assembly of the Lord; to the tenth generation no one related to him may do so. 3 No Ammonite or Moabite may enter the assembly of the Lord; to the tenth generation none of their descendants shall ever do so, 4 for they did not meet you with food and water on the way as you came from Egypt, and furthermore, they hired Balaam son of Beor of Pethor in Aram Naharaim to curse you. 5 But the Lord your God refused to listen to Balaam and changedthe curse to a blessing, for the Lord your God loves you. 6 You must not seek peace and prosperity for them through all the ages to come. 7 You must not hate an Edomite, for he is your relative; you must not hate an Egyptian, for you lived as a foreigner in his land. 8 Children of the third generation born to them may enter the assembly of the Lord.
So our list of people who are not allowed to join the assembly of the Lord are 1) eunuchs, 2) a person of illegitimate birth (or their descendants), 3) Ammonites & Moabites (or their descendants, and 4) Edomites & Egyptians (for a little while).
We CAN make sense of this, but it requires a little background knowledge. So let’s look first at what the “assembly of the Lord” is and then why these groups might be excluded.
ASSEMBLY OF THE LORD — I don’t want to belabour this, so let’s do a 10,000-foot overview here. But this does NOT refer to the general Hebrew/Christian/faith community. We see multiple examples of this in Scripture. Not to mention that this passage would then contradict things written both before AND after this passage. Also, while arguments are made for various interpretations of this phrase, I believe that the following is the superior explanation. This “assembly” is a guiding/governing assembly who will direct Israel (cf: Num 16:3; Jud 21:5,8; 1 Ki 12:3; Jer 26:17; Eze 16:40, 23:45-47; Mic 2:5).
So why would these people be excluded from that group?
EUNICHS — There are two primary reasons this group might be excluded. self-castration was closely related to paganism AND since Eunuchs could not have children, I can see why there would be concerns about how they might govern in light of that.
ILLEGITIMATE BIRTH — This was a person born of incest, adultery, or prostitution. These people are from broken homes. God would never exclude these people from his family, He cares for them. But having come from a broken home myself and despite having a dedicated mother who cared deeply about me, I still didn’t understand what made a good father or a healthy family. These people are not in a position to lead a nation. They need to focus on getting themselves straightened out.
AMMONITES & MOABITES — This group proved themselves to be enemies of Israel (as it says in the passage) so they clearly could not be trusted with positions of national leadership!
EDOMITES & EGYPTIANS — Edomites came from Esau, Jacob’s brother and the Egyptians (the people, not the abusive government… always worth remembering that the government ≠ the people) hosted them as sojourners.
Hopefully that helps you understand what I think is the best theory as to why this prohibition is in place AND what it actually IS.