“Although the adjective ... (‘righteous,’ or ‘just’) can be used of Jesus in Johannine thought (cf. 2:1; also John 5:30), referring to the judgement of Jesus as ‘just’), the subject of the present phrase, ‘he is … faithful and righteous,’ is obviously God (the ‘he’ of vv. 6 and 7).”
(Stephen S. Smalley, Word Biblical Commentary: 1, 2, 3 John, Vol. 51, p. 32
I agree with what Dr. Smalley says here. John is speaking in this verse about the Father (cf. 1 Timothy 6:16), not about Jesus.
If I were to amplify the passage I would render it something like this:
”If we confess our sins, he (God, the Father, YHWH) is faithful and just to forgive us our sins, and to cleanse us from all unrighteousness.”
That is what I - a Jewish monotheist who believes that Jesus of Nazareth is the Messiah, Son of the living God - would tell newbies.