Personal Finance Insider writes about products, strategies, and tips to help you make smart decisions with your money. We may receive a small commission from our partners, but our reporting and recommendations are always independent and objective.

commencement graduation student

Student loan debt is at an all-time high — the national total student debt is over $1.5 trillion and the average student loan debt per graduating student in 2018 who took out loans is $29,800, according to Student Loan Hero.

The weight of student loan debt has made it harder for millennials to save money to the point where some are playing catch-up — but the first rule of building wealth is that the earlier you start saving the better, thanks to compound interest.

So should millennials still invest while they have student loan debt — or should they pay it off first? It depends.

A 6% annual return on an investment portfolio serves as a benchmark, says one expert

If the interest rate for your student loan debt is high, experts say you should pay it off before investing, wrote Erin Lowry, founder of in her book, Broke Millennial Takes on Investing: A Beginner’s Guide to Leveling Up Your Money.”

While there isn’t a specific interest rate the industry agrees on, Sallie Krawcheck, CEO of Ellevest, told Lowry there’s a good guidepost to follow — a well-diversified investment portfolio should return about 6% annually, she said. Based on that, any student loan debt with interest higher than 7% should be paid off first, she said.

How much could your savings grow? Find out with this calculator from our partners:

Alex Benke, vice president of Financial Advice and Planning For Betterment, told Lowry that Betterment uses a 5% interest rate as the cut-off for student loan debt. You should have an emergency fund and no high-interest debt before starting to invest, he said.

But if your student loan debt has a low interest rate of less than 5% or 4%, it might be worthwhile to invest while paying it off, Julie Vitra, senior financial advisor with Vanguard Personal Advisor Services, told Lowry. “If you expect your portfolio to earn 6% to 8%, and your student loan debt is at 3%, 4%, or 5%, maybe, you’re better off investing your dollars,” Vitra said.

Consider the economic climate and company-match programs

Whether you invest while paying off student loan debt also depends on the climate in which you’re investing, according to Vitra.

“After the Great Recession, the stock market experienced a bull run from 2009 through 2018, but analysts and experts have been anticipating a market correction and less aggressive returns in the coming years,” Lowry wrote. “No one has a crystal ball, of course, but always do your research about recent returns before deciding to invest while paying off debt.”

All experts Lowry talked to said that regardless of your student loan debt interest rate, you should invest in an employer-matched retirement account — like a 401(k) — if the option is available.

A company match means your company will match whatever contribution you put towards your 401(k) up to a certain amount.

For example, say your annual salary is $100,000 and your company offers a “one-to-one” match up to 5% — if you contribute 5% of your salary ($5,000), your company will match it by contributing $5,000, making your actual investment $10,000 a year.

Essentially, it’s free money. Just keep in mind that the 401(k) contribution limit for 2019 is $19,000, according to the IRA.

Ready to invest? Consider these offers from our partners:

SEE ALSO: Nearly half of indebted millennials say college wasn’t worth it, and the reason why is obvious

DON’T MISS: 5 things millionaires are doing that millennials should know if they want to build wealth, according to experts

Join the conversation about this story »

NOW WATCH: Physicists have discovered that rotating black holes might serve as portals for hyperspace travel