The passage in question is this:
6:1 When people began to multiply on the face of the ground, and daughters were born to them, 2 the sons of God saw that they were fair; and they took wives for themselves of all that they chose. 3 Then the Lord said, “My spirit shall not abide in mortals forever, for they are flesh; their days shall be one hundred twenty years.” 4 The Nephilim were on the earth in those days—and also afterward—when the sons of God went in to the daughters of humans, who bore children to them. These were the heroes that were of old, warriors of renown. (Genesis 6:1-4)
Unfortunately we do not know for certain the original context of this passage. Scholars disagree about the exact age 0f this part of Genesis or why this section was written. From the simple surface of the text it is written, like most of Genesis, in Middle Biblical Hebrew (MBH), which places it anywhere between Solomon and the exile in Babylon (Late Biblical Hebrew), but the same scholars also view it as an editing, compiling and even translating from older sources, possibly much older sources. So we do not have any historical context other than the place of the story in the finished Genesis narrative, as literally antediluvian (before the flood) history.
The best we can do is try and interpret it in the light of related commentary elsewhere in the Bible.
Sons of God, angels?
We do fortunately know a lot about how Jews in the time of Jesus viewed, and disagreed over, this passage. Documents of Jesus’ time such as the Dead Sea Scrolls contain several expansions of the Genesis 6:1-4 story expanding the events into the fall of angels and their marriage with women on earth in apocryphal books like Jubilees and 1 Enoch – a strand in Jewish myth sometimes called “Enochic tradition”. Against this we also have rabbinic literature condemning these stories of angels marrying women as superstition.
Interestingly this is one of the few popular Jewish myths on which we have Jesus’ own commentary, where Jesus denies the idea that angels can marry, and identifies men not angels as ‘sons of God’.
For in the resurrection they neither marry nor are given in marriage, but are like angels in heaven. (Matthew 22:30)
Indeed they cannot die anymore, because they are like angels and are children of God, being children of the resurrection. (Luke 20:36)
There are those who have argued that these statements by Jesus are not intended as a contradiction of the Jubilees and 1 Enoch stories of angels marrying, and that his statements about angels marrying and sons of God from Jesus are just coincidence. That is a bit difficult to believe. The Enochic literature is one of the strongest strains in Jewish angelology at this period. Fragments of at least seven separate copies of 1 Enoch have been identified at Qumran, more than any other single text in the Dead Sea Scrolls. To say that Jesus simply hadn’t heard of this story is just not credible. To then say that the above statements do not directly contradict the Enochic tradition and align Jesus with the rabbis who rejected the story is also lacking one crucial evidence. If Jesus is not referring to the Enochic tradition of angelic sons of God marrying, then what other story of angels marrying exists in Jewish myth at this period. All surviving fragments, and there are hundreds of them, go back to the same expansion (or midrash) on Genesis 6.
So basically we know Jesus’ view on angels marrying and on who the sons of God were from Matthew 22:30 and Luke 30:36.
There were mighty men in those days, but that doesn’t mean they were offspring of angels. The Hebrew terms of Genesis 6:4 are used for many others at various times long after the flood: Nephilim (giants) in Numbers 13:33, men of renown in Numbers 16:2; 1 Chronicles 5:24; 12:30 and mighty men in Genesis 10:8-9; Joshua 6:2; 1 Chronicles 12:1,4,8,21,25,28,30, etc. None of these people were born of angels either.
God’s response in Genesis 6:3 is to warn of the coming destruction of man; it is man that is at fault, not angels (who cannot sin anyway (Psalm 103:20; Hebrews 1:14); if they could sin, they would also die (Romans 6:23), but angels cannot die (Luke 20:35-36)). So the context of Genesis 6 confirms these sons of God are people — people who had been faithful, but who compromised themselves by marrying ‘any they chose’ (Genesis 6:2).
This failure of God’s people is the lesson Jesus Christ draws from the incident as particularly relevant to people in the day of his return: there is more to think about in life than attractive women and other sensory pleasures.
“Just as it was in the days of Noah, so will it be in the days of the Son of Man. They were eating and drinking and marrying and being given in marriage, until the day when Noah entered the ark, and the flood came and destroyed them all.” (Luke 17:26-27)
‘Sons of God’, further Old Testament and New Testament usage.
Aside from the key reference above where Jesus uses ‘sons of God’ to refer to believers in the context of angels not marrying, the rest of the Old and New Testament provide copious support for Jesus’ view of the term.
The phrase ‘sons of God’ refers to faithful people in the following verses (among others):
“You are the sons of the Lord your God.” (Deuteronomy 14:1)
In Christ Jesus you are all sons of God, through faith. (Galatians 3:26)
We are debtors, not to the flesh, to live according to the flesh. For if you live according to the flesh you will die, but if by the Spirit you put to death the deeds of the body, you will live. For all who are led by the Spirit of God are sons of God. (Romans 8:12-14)
The similar phrase ‘children of God’ also refers to faithful people in the following verses (among others):
To all who did receive him, who believed in his name, he gave the right to become children of God (John 1:12)
Do all things without grumbling or questioning, that you may be blameless and innocent, children of God (Philippians 2:15)
See what kind of love the Father has given to us, that we should be called children of God; and so we are…Beloved, we are God’s children (1 John 3:1-2)
So it is consistent to interpret sons of God as faithful people. Then the daughters of man are presumably by contrast unfaithful people. The phrase ‘children of man’ does indeed carry that flavour in several passages:
The faithful have vanished from among the children of man…On every side the wicked prowl, as vileness is exalted among the children of man. (Psalm 12:1,8)
I lie down amid fiery beasts—the children of man, whose teeth are spears and arrows, whose tongues are sharp swords. (Psalm 57:4)
The heart of the children of man is fully set to do evil. (Ecclesiastes 8:11)
The hearts of the children of man are full of evil, and madness is in their hearts while they live, and after that they go to the dead. (Ecclesiastes 9:3)
“All sins will be forgiven the children of man, and whatever blasphemies they utter” (Mark 3:28)
Genesis 6:2 mentions only faithful sons and unfaithful daughters; this is not because there were no faithful women or unfaithful men, but because it is about marriage and marriage was customarily initiated by the man.
Fundamentally this is an odd and difficult passage. The surest anchor point in the entire discussion remains Jesus’ own verdict that ‘angels do not marry’, and ‘sons of God’ are believers.
Note: For further discussion of the Enochic material current in Jesus’ day, see also the mention of ‘angels that sinned’ in 2 Peter and Jude. Read superficially those passages are often taken as agreeing with the Enochic fallen angels story which they undeniably reference, but closer examination shows that Peter and Jude were in fact opposing men who taught those ideas in their own terminology, not approving the stories. In other words they agreed with Jesus on angels not marrying.