Romans 4:1-5 NIV
What then shall we say that Abraham, our forefather according to the flesh, discovered in this matter? If, in fact, Abraham was justified by works, he had something to boast about—but not before God. What does Scripture say? “Abraham believed God, and it was credited to him as righteousness.”
Now to the one who works, wages are not credited as a gift but as an obligation. However, to the one who does not work but trusts God who justifies the ungodly, their faith is credited as righteousness.
NIV: New International Version