Every sin consists formally in aversion from God…. Hence the more a sin severs man from God, the graver it is. Now man is more than ever separated from God by unbelief, because he has not even true knowledge of God: and by false knowledge of God, man does not approach Him, but is severed from Him…. Therefore it is clear that the sin of unbelief is greater than any sin that occurs in the perversion of morals.
Summa Theologiae, II-II, q. 10, a. 3.