John’s ties knowing you have eternal life to believing in the name of the Son of God. Confidence of eternal life comes from believing in Jesus.
Those who believe that Jesus is the Son of God, practice obedience, and love others, can be assured that they have eternal life. If you do believe in an ongoing and obvious way, then you can be confident that you not only have eternal life, but that your heavenly Father hears you when you pray, especially when you're interceding for a brother or sister. When we do this, John is certain that God will give them life. Therefore, believer’s need to seek and learn God’s will in order to pray properly.
The first thing we’re supposed to do when we see a professing believer in sin is to pray for them. The practice of sin is NOT acceptable to Christians, and if we see sin in a brother or sister’s life, we should intercede for them, both in prayer and in person.
The Christian who doesn’t make a practice of sinning is protected by God. “The One who is born of God keeps him” - it’s Christ who keeps us, not ourselves. Because the Son keeps the believer safe, they cannot persist in or continually practice sin. It is contrary to their nature. It is contrary to their Protector.