The Catechism in Questions & Answers

59. What does it mean to say that “God is the Righteous One”?

Everything that God does is right. He makes no mistakes. “His work is perfect; for all His ways are justice” (Deuteronomy 32: 4). Human beings can depend on God’s righteousness and reliability: “He who calls you is faithful, who also will do it” (1 Thessalonians 5: 24).
Another expression of God’s righteousness are His laws, for example, that human beings reap what they sow (cf. Galatians 6: 7), and that the wages of sin is death (cf. Romans 6: 23).
However, God’s grace stands above everything else. This too is part of His righteousness. Through Jesus Christ, sinners—who have only earned punishment— can receive grace. As a result, God will no longer hold their sins and transgressions against them.

“The entirety of Your word is truth, and every one of Your righteous judgements endures forever.”
Psalm 119: 160
“Lord God Almighty, true and righteous are Your judgements.”
Revelation 16: 7
“[They are] justified freely by His grace through the redemption that is in Christ Jesus.”
Romans 3: 24