For in (the gospel) the righteousness of God is revealed from faith to faith; as it is written, "The just shall live by faith." (Rom 1:17)
But now the righteousness of God apart from the law is revealed, being witnessed by the Law and the Prophets, even the righteousness of God, through faith in Jesus Christ, to all and on all who believe. (Rom 3:21-22)
In the above two passages, Paul tells us that something is revealed in the gospel: The righteousness of God.
God's righteousness is what the gospel is about. The gospel isn't about the attempts of people to earn or maintain righteousness through the things they do. It's about the gift of God's very righteousness. This gift is given freely to all who believe.
As you look in your Bible, you'll see that in between the two passages above, there are sixty-four verses that essentially tell us about the unrighteousness of man. These verses are not what the gospel is about! These sixty-four verses, from Romans 1:18 all the way to Romans 3:20, were written to show us the reason the gospel was needed. That is, they were written to show us the reason the righteousness of God needed to be given to us as a gift, by grace through faith. Paul writes about how the wrath of God was "revealed from heaven against all ungodliness and unrighteousness of men..." He lists all kinds of ways in which the ungodliness and unrighteousness of men has been demonstrated.
As all of this continues into Chapter 2, Paul makes the case to his fellow Jews that it's not only the Gentiles (non-Jews) who have missed the mark, but they themselves are also transgressors of the very law of God that they make their boast in! In other words, Paul points out that we're all in the same boat in regards to "the ungodliness and unrighteousness of men," so there's no room for anyone to judge or condemn anyone else! All (both groups: Jews and Gentiles) have sinned and fallen short of the glory of God. "For we have previously charged that Jews and Gentiles alike are all under sin." (Romans 3:9). "There is no one righteous, not even one." (Romans 3:10).
The only thing the law of God had done was to reveal sin. "BUT NOW," Paul writes in Romans 3:21, "the righteousness of God apart from the law is revealed... even the righteousness of God, through faith in Jesus Christ, to all and on all who believe." The law revealed sin, but could do nothing about it. The gospel revealed God's righteousness, which we receive as a gift.
Can you see what Paul was doing, by first telling us in Romans 1:17 that the gospel revealed God's righteousness, and then spending quite a bit of time (64 verses) telling us about man's unrighteousness? Sadly, many in the church have used a portion of those 64 verses to pronounce guilt, judgment and condemnation upon not only unbelievers, but also upon their fellow believers! But that was never the reason those verses were written. The reason Paul built this lengthy case for the unrighteousness of man was to show why righteousness could never be earned or attained by our performance. Only God's perfect righteousness would ever do, and the only way anyone can attain it is to receive it freely as a gift!