THIS MIGHT SURPRISE YOU
The answer
Genesis 4, in God's words to Cain. Cain is angry that God accepted his brother Abel's offering and not his own. God warns him: "sin is lurking at the door; its desire is for you, but you must master it" (Genesis 4:7). The garden story in Genesis 3 speaks of opened eyes, of knowing good and evil, and of nakedness. The word sin is not in it.
Why it’s interesting
The New Oxford Annotated Bible, a study Bible, calls Genesis 4:7 a difficult verse. It reads sin there as tied to the risk Cain runs if he does not handle his anger well. God speaks before Cain has done anything, so the word's first appearance is a warning.
Scholarly consensus
Learn the Bible.
Not just the stories, but the history, authorship, and scholarship behind it.