"If we confess our sins, he is faithful and just and will forgive us our sins and purify us from all unrighteousness" (1 John 1:9).
This promise has two parts: 1) He will forgive us our sins, and 2) He will purify us from all unrighteousness. The sins that get forgiven are the ones confessed. “All unrighteousness” is more than just these sins; it is everything else that is unrighteous in us. God will purify us from all of this. Look back at verse seven:
"But if we walk in the light, as he is in the light, we have fellowship with one another, and the blood of Jesus, his Son, purifies us from all sin" (1 John 1:7).
Notice how the last phrase parallels verse 9. Verse 7: “purifies us from all sin.” Verse 9: “purifies us from all unrighteousness.” The verb “purifies” has the sense of continual activity, i.e., He “keeps on purifying.”There are conditions for this complete and continual purifying. Verse 7: “If we walk in the light as He is in the light.” Verse 9: “If we confess our sins.” Meeting these conditions puts the work of God into effect in our lives. However, the conditions are secondary to the blood of Jesus and the justice and faithfulness of God. “He is faithful and just” (v. 9). The real cause of this wonderful forgiveness is God.