Maybe 60% of the budget of Stanford is from research grants from the US Federal Government. For the students, there are also scholarships, e.g., from the NSF, NIH, etc., which is more "government" support.
Be not at all in doubt: Look at the Stanford campus with all its buildings, lawns, people, equipment, etc. and know that nearly all of it is paid for by the US Federal government.
Gifts from successful alums are also a big source now:
Yes, I can believe that the Stanford alums have especially good reason and ability to be 'grateful'! Good for Stanford; thank you, thank you, thank you Dean Terman!
Still, nearly all the world's top research universities are in the US, and the main reason is that right after WWII Ike and others concluded that research in math, physical science, and engineering were just crucial for US national security. Congress has gone along. Any significant claim that the US is falling behind in research will open Congress's funding for the usual suspects NSF, NIH, DoE, DARPA, etc.
Net, no way, not a chance, will Congress permit US research universities to fall behind: From Congress all it takes is money, that is easy for Congress to vote, and actually in the big picture it doesn't take very much money.
Also, all things considered, the money is relatively well spent. Evidence: Getting those grants is DARNED competitive. Want to get promoted at a top US research university? Get a grant!
And there is a secret -- hush, hush! About 60% of the grant money, for math, physical science, and engineering, goes to 'overhead' which ends up good for the English, modern dance, French literature, and art history departments! Likely helps pay for the university theater, art gallery, string quartet concert series, etc.!
Don't tell anyone that Federal taxes are supporting string quartets!
Also looked to me that the Stanford lawn was in nice shape!