As with any other sin, breaking any of the Ten Commandments doesn’t prevent you from entering the gates of heaven. What needs to happen before God gives forgiveness is that the person needs to repent, showing profound regret for their mistakes.