This is a common question I get from Millennials (even some Gen Xers) and have seen multiple times on personal finance subreddits.

But before I start, I want to emphasize one thing: if you have student loans with a high-interest rate (say more than 6% or so), you should first look into refinancing that to a lower interest rate. I’ve come across situations where graduates have $100,000 in loans at 10% interest.

That’s $10,000 per year in interest!

In which case you should focus your energy into refinancing that loan. Here’s a recent US news piece on student loan refinancing and consolidation , or discuss options with a financial advisor.

Alright, now to the question at hand. I’ll use a couple of examples to illustrate this. One is Jack, who just finished his undergrad with $25,000 in student loans and recently landed a job that pays $60,000 a year.

Then we have Lisa, who just finished medical school residency with $100,000 in student loans. She is starting a job that pays $200,000 a year.

Each of their student loans is at 6% interest and have to be repaid in 10 years. This translates to a $278 monthly payment for Jack and $1,110 for Lisa.

Both want to be rid of the student loans sooner rather than later, say in 6 years. Jack wants to pay an additional $150 a month (so $1,800 a year), which works out to 3% of her $60,000 income.

Lisa wants to pay an additional $500 a month ($6,000 a year), which also works out to 3% of her $200,000 annual salary.

Important note: they both make their minimum payments each month. What I’m discussing here is over and above that.

Paying more than the minimum required ensures they end up loan-free in about 6 years. They also save quite a bit of interest, as the graphic below illustrates.

### ** The magic of compounding early **

Now Jack and Lisa could also be making contributions to their company 401k plans, which they don’t because they want to pay off their student loans early.

Also, their companies give them a ** 3 percent match ** — which means, if they contribute at least 3 percent of their income to their 401k plan, the company makes an equivalent 3 percent contribution.

Let’s also assume they each get a 2 percent raise every year.

What does all this mean in dollar terms?

Jack skips making a $1,800 annual contribution to his 401k plan for the first 6 years (while he makes additional payments towards his student loan). Though the 2 percent annual raise means that after the first year he actually skips putting in more than $1,800. By year 6 he could be adding almost $2,000 towards his 401k plan.

The next chart illustrates the difference in his retirement account balance over 40 years — with a prepayment of the student loan vs putting the extra money into his 401k plan and getting the employer match. I assume a 6% average rate of return over 40 years.

The difference is enormous. Contributing to the 401k plan over the first six years (instead of prepaying the student loan) would have netted close to $200,000 more for his retirement after 40 years! Even after 30 years, the difference is significant: about $106,000. Recall that he would’ve saved about $3,700 by paying off his student loan early.

The story is similar to Lisa, except that the numbers are even larger because of her higher income. She skips making a $6,000 annual contribution to her 401k plan for the first 6 years. And thanks to the 2 percent annual raise, by year 6 she is forgoing about $6,600 in contributions to her retirement plan. I assume the same average 6% return over 40 years. Her chart is shown below.

If Lisa had contributed 3 percent of her income to her 401k plan (and received the employer match as a result), instead of paying off her student loan four years early, her retirement account would be larger by almost $636,000! A balance of $2.42 million versus $1.79 million if she waited six years to start making retirement contributions.

Even after 30 years, the difference had grown to about $355,000.

At the same time, pre-paying her loan saved her a little over $13,000 in total interest.

You see how compounding makes a difference, especially when you start early. The opportunity cost of waiting even just six years to start making 401k plan contributions is significant.

Another thing I left out of here is the fact that 401k plan contributions are tax-deferred . In other words, you don’t pay annual taxes on any contributions you make to the 401k plan — you just pay taxes when you eventually withdraw money in retirement. This is an added benefit for 401k plan contributions, one that I will discuss in another post.

Obviously, Jack and Lisa’s examples are fiction but the idea is to illustrate the idea of compounding investments early.

One big assumption I made here is that both individuals have an either-or choice i.e. either use the ** additional savings ** to pay off the student loan early or make retirement contributions. The additional savings is key here. I already assumed Jack and Lisa were making minimum payments toward their student loans.

In real life, you could perhaps stretch to save even more, allowing you to do both. And for a lot of people, getting rid of a loan early gives an emotional peace of mind that trumps the math.

You need to figure out, and just as important, get on a path that works for you while being informed about your choices.