"For Jesus is the one referred to in the Scriptures, where it says, 'The stone that you builders rejected has now become the cornerstone.' There is salvation in no one else! God has given no other name under heaven by which we must be saved."
- Acts 4:11-12
The conventional wisdom about what happens when you die is that you will stand before God, and if you did enough good works that outweighed your bad works, then you get into heaven, because heaven is for good people. And good people go to heaven.
Then the other belief is that if you have done enough bad things that outweigh your good works, then you will go to hell, because hell is for bad people. Heaven is for good people who get in by good works, while hell is for bad people who do bad things.
But that is not what the Bible teaches. The Bible teaches that hell is prepared for the devil and his angels (see Matthew 25:41); it isn't prepared for bad people at all.
Heaven is the dwelling place of God, and the way you get into heaven is on the basis of what you did with Jesus. What God will want to know is did you believe in Jesus Christ?
Even if you have lived a wicked life and sinned throughout all of it, if on your deathbed you were to call out to the Lord Jesus Christ in genuine repentance, you would go to heaven. But if you lived a good life and have been a relatively moral person and have done good deeds, but you have never put your faith in Jesus Christ, then you would not go to heaven. And by the way, your good works never would outweigh your bad works. So be thankful that is not what you will be judged for.
The assurance that we will go to heaven is not as our culture often sees it, but this is as the Bible teaches it. It is the Son question-not the sin question.