Being righteous is not some minor attribute of God. It is a vital characteristic of His very identity. God is righteous by nature and not just some of the time; He is always righteous "in all His ways" (Ps. 145:17).
God's law for mankind is righteous (Rom. 8:3-4). His word that communicates His will is righteous (Ps. 119:123, 138). Psalm 119 is the longest of all of the psalms. The importance and magnitude of God's word is highlighted in this psalm perhaps more than in any other text of scripture. His word is referred to, in some way, in every one of the 176 verses in this psalm with the exception of approximately five. The Bible is not just another book; it is a treatise on righteousness.
As God's word is righteous, it should not be surprising that His judgments, based upon His word, are also righteous. The apostle John wrote, "true and righteous are Your judgments" (Rev. 16:7). On that final day of reckoning mankind can take heart in knowing that the judge before Whom they will appear will be righteous beyond comparison, and He will have full and accurate knowledge of all facts pertaining to their lives. There will be no inequity in His judgments.
Righteousness is so fundamental to God's character that He cannot abide unrighteousness. Living unrighteously automatically disassociates a person from God (1 Jn. 1:5-6). One cannot live in sin and walk with God at the same time (1 Jn. 3:6-10). It's like oil and water, the two practices don't mix. The world needs to learn this lesson. Our culture has tried to clean up the image of unrighteousness. Committing fornication and even adultery are depicted as being good under given circumstances. Lying, cheating and stealing are OK, if conditions justify it. Such convoluted reasoning is influenced by the devil. "Woe to those who call evil good, and good evil..." (Isa. 5:20).
God "loves righteousness" (Ps. 11:7), and He watches over the righteous (1 Pet. 3:12). We need to realize how imperative it is that we live righteous lives (1 Pet. 4:17-18). The unrighteousness of mankind is what sent Jesus to the cross (Rom. 5:8). We should never minimize the gravity of His sacrifice through a frivolous attitude about sin. Even the effectiveness of our prayers can be compromised by living unrighteous lives (Jas. 5:16).
God has not left us without hope. He will count us righteous as we are born again through baptism into Christ (1 Jn. 2:28-29; 1 Pet. 1:22-23). Then we can look forward to spending eternity with our righteous Heavenly Father in the land of the righteous...