God is light, and no darkness at all is found in Him (1 John 1:5). There is no sin in God whatsoever.
Jesus is the “light of the world” (John 8:12). Following Him means not walking in darkness any longer. It means “go and sin no more” (John 8:11).
If a Christian claims to be in fellowship with God but is walking in darkness (living in sin), they are lying and not practicing the truth (1 John 1:6). This doesn’t mean living a sinless life (as we are about to see).
It is important to note here that 1 John 1:6 demonstrates that it is possible for a Christian to walk in darkness. John is writing this letter to Christians. It is possible for a Christ to “fall from grace,” to turn back to sin (2 Peter 2:18-22).
Walking in the light means we are following Jesus and not sin. It means we have “set our mind on things above, and not on things on the earth” (Colossians 3:1-3). It means living a holy life (1 Peter 1:13-16).
If a Christian is walking in the light, then they continue to have fellowship with God, and they continue to be cleansed by the blood of Jesus (1 John 1:7). Walking in the light doesn’t mean living a sinless life - why else would those walking in the light continue to need the blood of Jesus cleansing them from all sin?
It does mean confessing our sins and striving not to sin with everything we have (1 John 1:8-2:1).
If this is how we are “walking,” then we can take great comfort in knowing that if we do stumble and sin, “we have an Advocate (Helper) with the Father, Jesus Christ the righteous” (1 John 2:2).
So the comfort of walking in the light as He is in the light is this
God has supplied the Way out of darkness and into the light with Him (Colossians 1:13-14). The only Way is Jesus Christ (John 14:6). Those who are baptized into Him (Galatians 3:26-27) have redemption and forgiveness through His blood (Colossians 1:14).
Those who have been transferred out of darkness and into the light have the comfort of the continual cleansing of Jesus’ blood and the comfort of knowing Jesus is our Advocate (Helper) with the Father.
While God does not require sinless perfection for us to walk in the light, He does require our humility regarding our sins (1 John 1:8) and our submission in continuing to confess our sins to Him (1 John 1:9).
Those walking in the light have a Helper - Jesus Christ the righteous One, the sinless One who died for us in our place (1 John 2:1-2; 2 Corinthians 5:21).
The comfort offered to those walking in the light is that you can know eternal life awaits you (1 John 5:13).