Let's take a look at my salary history. I am a PhD, I didn't enter the Real World Job Market until 2001, when I was 28 (others in my cohort went straight from college to SWE, while I spent 10 years just doing research).
2001: SWE at UCSF, making about $75K/yr. This is roughly triple my graduate student salary and higher than my postdoc salary.
2007: Architect at Genentech. Make about $100K/year
2008: Join Google as L5 with a starting bonus of $25K, $125K salary, and about $100K in stock options. Stock options are refreshed every year. One year, Eric Schmidt gives everybody a 10% raise. I get promoted once.
2019: leave to work at a startup for a year, same base pay as Google, and stock grants that are now worth $1M but aren't fungible.
2021: Leave Google as L6 with base pay of $225K, 15% bonus target (which I get), a $45K annual bonus, and $700K stock vesting over four years. I count this as "around $450K/year total comp" before taxes etc.
If I had managed 2012-2016 better, I'd be an L7 or more, making about $550K/year total comp. However, these are all exceptional situations made possible by the insanity that is Google.