(Numbers 32:1:) "Now the children of Reuben <and the children of Gad> had much livestock," etc. Let our master teach us: how many good gifts were created in the world? [Thus our masters taught: The Holy One, blessed be He, created three gifts in the world:] wisdom, strength, and wealth. If a person merits one of them, he has taken the delight of the whole world. When? At the time when they come from the Holy One, blessed be He, and come through the power of the Torah. But a person's strength and his wealth are nothing, for thus said Solomon: "Again I saw under the sun that the race is not to the swift, nor the battle to the strong, neither yet bread to the wise, nor yet riches to the discerning," etc., "for time and chance happen to them all" (Ecclesiastes 9:11). And so said Jeremiah: "Thus says the LORD: Let not the wise man boast in his wisdom, nor let the mighty man boast in his might, let not the rich man boast in his riches" (Jeremiah 9:22 [23]). And these gifts, since they do not come from the Holy One, blessed be He, in the end are cut off from him.
Three Gifts of God - Why Wisdom Strength and Wealth Must Come from Above
Midrash Tanchuma Buber, Matot 7:1
ומקנה רב היה לבני ראובן וגו' (במדבר לב א). ילמדנו רבינו כמה מתנות טובות נבראו בעולם, [כך שנו רבותינו שלש מתנות ברא הקב"ה בעולם] חכמה וגבורה ועושר, זכה אדם לאחת מהן נטל חמדת כל העולם, אימתי בזמן שבאות מאת הקב"ה, ובאות בכח התורה, אבל גבורתו ועושרו של אדם אינן כלום, שכן אמר שלמה שבתי וראה תחת השמש כי לא לקלים המרוץ ולא לגבורים המלחמה וגם לא לחכמים לחם וגם לא לנבונים עושר וגו' כי עת ופגע יקרה את כולם (קהלת ט יא), וכן אמר ירמיה כה אמר ירמיה כה אמר ה' אל יתהלל חכם בחכמתו ואל יתהלל הגבור בגבורתו אל יתהלל עשיר בעשרו (ירמיה ט כב), ומתנות אלו כיון שלא באות מן הקב"ה סופן להפסק ממנו.