The exact math behind using 401k loan to pay down debt

 Posts: 21
 Joined: Tue Mar 24, 2015 11:42 pm
The exact math behind using 401k loan to pay down debt
would like some opinions on this please
I currently have a sizable 401k that is entirely invested in a (lowcost) stable value fund (think short term bonds). The equity investment funds available in the 401k are all high fee (>1%) with no index options, so I park the balance in the low fee stable value and use it as the cash/shortterm bond portion of our asset allocation.
The interest rate on a 401k loan is 4.125%. Taking a loan does not affect ability to contribute to 401k, which I max every year due to being in highest tax bracket. My job is stable and I have no plans to leave it in the near future. If I were to get laid off I would receive a huge severance package as well as deferred comp that vests immediately, so I would easily be able to pay off any 401k loan balance and have a big amount left over.
We have various fixed rate mortgages on investment properties, the highest being 4.625%. We also have many taxable accounts with large balances fully invested in equity index funds. Given the current 0% rate environment, I try to keep as little cash as possible, except in the 401k due to the lack of low cost investment options.
The question I have is, does it make sense to take a loan on the 401k at 4.125% and use proceeds to pay down the highest rate (4.625%) mortgage? I figured that since the 4.125% 401k loan interest would be paid to myself, using loan proceeds to pay off higher rate debt would make sense since I have no plans to invest the 401k balance in anything other than cashlike equivalents, and have no concerns about ability to repay the loan if my employment situation were to change.
Are there any other considerations I am missing? One thought was that the interest I pay myself which accrues in the 401k account would be paid with aftertax dollars, but would then again be taxed upon eventual withdrawal  is this correct?
Thanks in advance
I currently have a sizable 401k that is entirely invested in a (lowcost) stable value fund (think short term bonds). The equity investment funds available in the 401k are all high fee (>1%) with no index options, so I park the balance in the low fee stable value and use it as the cash/shortterm bond portion of our asset allocation.
The interest rate on a 401k loan is 4.125%. Taking a loan does not affect ability to contribute to 401k, which I max every year due to being in highest tax bracket. My job is stable and I have no plans to leave it in the near future. If I were to get laid off I would receive a huge severance package as well as deferred comp that vests immediately, so I would easily be able to pay off any 401k loan balance and have a big amount left over.
We have various fixed rate mortgages on investment properties, the highest being 4.625%. We also have many taxable accounts with large balances fully invested in equity index funds. Given the current 0% rate environment, I try to keep as little cash as possible, except in the 401k due to the lack of low cost investment options.
The question I have is, does it make sense to take a loan on the 401k at 4.125% and use proceeds to pay down the highest rate (4.625%) mortgage? I figured that since the 4.125% 401k loan interest would be paid to myself, using loan proceeds to pay off higher rate debt would make sense since I have no plans to invest the 401k balance in anything other than cashlike equivalents, and have no concerns about ability to repay the loan if my employment situation were to change.
Are there any other considerations I am missing? One thought was that the interest I pay myself which accrues in the 401k account would be paid with aftertax dollars, but would then again be taxed upon eventual withdrawal  is this correct?
Thanks in advance
Re: The exact math behind using 401k loan to pay down debt
I believe this is the definitive post on calculating whether a 401k loan to either invest in taxable or prepay debt in taxable (functionally the same thing): http://www.bogleheads.org/forum/viewtop ... 8#p1589509. So much so that I spent a long time studying it and adapting it into a spreadsheet I could use as a decision tool.
Here is what I end up doing. I don't know if the variables are exactly the same since I went through this a long time ago, but I tried to interpret it in a way that makes sense for me. I have a TSP account hence the references to TSP.
Rtax = return in taxable account. Can be the return from prepaying another loan (mortgage, auto, student, etc), or the return on a fixed income investment. Use taxadjusted value, e.g. reduce rate on mortgage if you itemize, or reduce return of fixed income by your marginal tax rate.
Rtsp = return in TSP (401k). For me, G Fund interest rate. For you, return of stable value fund. For others, expected return on a safe fixed income investment in the 401k.
L = TSP (401k) loan rate.
T = Tax on TSP (401k) distributions. Estimate of marginal tax rate in retirement. Take into account Roth vs Traditional split for your loan, i.e. loans typically disburse from a 401k in the same Roth/Traditional proportion as the account's split, and are repaid in the same proportion. For example, if your estimated marginal tax in retirement is 25% and your 401k was 100% Roth, T = 0%. If 100% Traditional, T = 25%. T is a linear combination of 0% and 25% for anything between those values.
Then compare two values.
Rtax  Rtsp * (1  T)
L * T
If (Rtax  Rtsp * (1  T)) > (L * T), then take funds from the TSP and invest in taxable/prepay debt. Equivalently, don't prepay TSP loan.
If (L * T) > (Rtax  Rtsp * (1  T)), then do not take a TSP loan. Equivalently, prepay TSP loan before investing in taxable or prepaying debt.
Hope this helps.
Here is what I end up doing. I don't know if the variables are exactly the same since I went through this a long time ago, but I tried to interpret it in a way that makes sense for me. I have a TSP account hence the references to TSP.
Rtax = return in taxable account. Can be the return from prepaying another loan (mortgage, auto, student, etc), or the return on a fixed income investment. Use taxadjusted value, e.g. reduce rate on mortgage if you itemize, or reduce return of fixed income by your marginal tax rate.
Rtsp = return in TSP (401k). For me, G Fund interest rate. For you, return of stable value fund. For others, expected return on a safe fixed income investment in the 401k.
L = TSP (401k) loan rate.
T = Tax on TSP (401k) distributions. Estimate of marginal tax rate in retirement. Take into account Roth vs Traditional split for your loan, i.e. loans typically disburse from a 401k in the same Roth/Traditional proportion as the account's split, and are repaid in the same proportion. For example, if your estimated marginal tax in retirement is 25% and your 401k was 100% Roth, T = 0%. If 100% Traditional, T = 25%. T is a linear combination of 0% and 25% for anything between those values.
Then compare two values.
Rtax  Rtsp * (1  T)
L * T
If (Rtax  Rtsp * (1  T)) > (L * T), then take funds from the TSP and invest in taxable/prepay debt. Equivalently, don't prepay TSP loan.
If (L * T) > (Rtax  Rtsp * (1  T)), then do not take a TSP loan. Equivalently, prepay TSP loan before investing in taxable or prepaying debt.
Hope this helps.

 Posts: 21
 Joined: Tue Mar 24, 2015 11:42 pm
Re: The exact math behind using 401k loan to pay down debt
Ketawa,
Very helpful  thanks!
Very helpful  thanks!
Re: The exact math behind using 401k loan to pay down debt
Some actual numbers from a couple of my loans.
Rtax = 1.99% (auto loan)
Rtsp = 2.00% (G fund rate)
L = 1.625% (existing TSP loan rate)
T = 18% (25% estimate of my marginal tax rate in retirement, loan was disbursed as 73% Traditional/27% Roth)
Rtax  Rtsp * (1  T) = 0.36%
L * T = 0.30%
Result: take TSP loan, prepay auto loan.
Obviously, this is solely based on the math. There can be many other considerations than this.
And I think this final step I take is valid. Let's say the amount in question is $15k. Annual advantage of taking TSP loan = (0.36%  0.30%) * $15k = $9. So in reality, this is basically nothing.
I have an auto loan (3 yr), mortgage (30 yr), residential TSP loan (15 yr), and general TSP loan (5 yr). Before someone slams me for "borrowing from my retirement", I also have $25k sitting in CDs and prepaid card accounts in taxable making 5%+ FDIC insured as part of my fixed income allocation. But anyway, I ended up deciding for my personal situation I should follow these guidelines after running the numbers:
1. Best to prepay auto loan first. Mortgage marginally better on $$$, but prepaying auto loan has more immediate cash flow benefits, e.g. can count payments towards future payments.
2. Mortgage is good to prepay as long as Rtsp < 2.375%.
3. General TSP loan better to prepay than residential TSP loan due to more immediate cash flow benefits. Higher rate on my residential loan, but TSP loans can be reamortized an unlimited number of times and the general loan has a shorter term.
Hopefully walking through my thought process helps someone with thinking about these problems.
Rtax = 1.99% (auto loan)
Rtsp = 2.00% (G fund rate)
L = 1.625% (existing TSP loan rate)
T = 18% (25% estimate of my marginal tax rate in retirement, loan was disbursed as 73% Traditional/27% Roth)
Rtax  Rtsp * (1  T) = 0.36%
L * T = 0.30%
Result: take TSP loan, prepay auto loan.
Obviously, this is solely based on the math. There can be many other considerations than this.
And I think this final step I take is valid. Let's say the amount in question is $15k. Annual advantage of taking TSP loan = (0.36%  0.30%) * $15k = $9. So in reality, this is basically nothing.
I have an auto loan (3 yr), mortgage (30 yr), residential TSP loan (15 yr), and general TSP loan (5 yr). Before someone slams me for "borrowing from my retirement", I also have $25k sitting in CDs and prepaid card accounts in taxable making 5%+ FDIC insured as part of my fixed income allocation. But anyway, I ended up deciding for my personal situation I should follow these guidelines after running the numbers:
1. Best to prepay auto loan first. Mortgage marginally better on $$$, but prepaying auto loan has more immediate cash flow benefits, e.g. can count payments towards future payments.
2. Mortgage is good to prepay as long as Rtsp < 2.375%.
3. General TSP loan better to prepay than residential TSP loan due to more immediate cash flow benefits. Higher rate on my residential loan, but TSP loans can be reamortized an unlimited number of times and the general loan has a shorter term.
Hopefully walking through my thought process helps someone with thinking about these problems.
Last edited by Ketawa on Thu May 21, 2015 7:19 am, edited 1 time in total.
Re: The exact math behind using 401k loan to pay down debt
Great thread. Never thought about doing this. I too have a 401K account that has crappy fees so I put it in the lowest cost fund, but that isn't really generated much of a return.
Would you ever use this to take a loan on your 401K, put it into a lowercost aftertax fund, then pay off your loan through distributions from your aftertax fund?
Would you ever use this to take a loan on your 401K, put it into a lowercost aftertax fund, then pay off your loan through distributions from your aftertax fund?
Re: The exact math behind using 401k loan to pay down debt
Why use your retirement marginal tax rate in L*T? You have to pay taxes in retirement on the final distribution of that amount anyways at a rate of T. But the additional taxes you have to pay now during the repayment of the loan are at your current marginal tax rate (call it T_current), because you repay with aftertax dollars. I'd say that should be L*T_current. If T_current > T, that shifts the equation in favor of not taking the loan. If T_current < T, it shifts it the other way.Ketawa wrote:Then compare two values.
Rtax  Rtsp * (1  T)
L * T
Re: The exact math behind using 401k loan to pay down debt
What do you mean by "you repay with aftertax dollars"? You need to be more specific. My guess is that you're referring to the notion that you pay back a 401k loan in future years with income that is taxed once, and then will be taxed again upon withdrawal from the 401k. That isn't true, since the proceeds from loan have either never been taxed or have been taxed once and won't be taxed again.Kosmo wrote:Why use your retirement marginal tax rate in L*T? You have to pay taxes in retirement on the final distribution of that amount anyways at a rate of T. But the additional taxes you have to pay now during the repayment of the loan are at your current marginal tax rate (call it T_current), because you repay with aftertax dollars. I'd say that should be L*T_current. If T_current > T, that shifts the equation in favor of not taking the loan. If T_current < T, it shifts it the other way.Ketawa wrote:Then compare two values.
Rtax  Rtsp * (1  T)
L * T
The funds from disbursement of a 401k loan have never been taxed if they are from a Traditional 401k, and will be taxed once eventually when you take distributions after repayment.
The funds from disbursement of a 401k loan have been taxed once if they are from a Roth 401k, and will not be taxed again.
You probably have to go back to the original thread for a longer explanation of why it's the tax rate in retirement. But it makes sense, because extra taxes are only paid on the small amount of loan interest (i.e. extra funds you have to put in your 401k to repay the loan), which is why it's L * T.
Re: The exact math behind using 401k loan to pay down debt
For a simple example of why T should be the marginal tax rate in retirement on the 401k loan proceeds, consider a hypothetical where you have a 401k that is 100% Roth and 100% Roth makes sense in the future for you. Your marginal tax rate now is 20%. You can invest in a fixed income investment making 10% in taxable, or making 8% in the 401k. I will also compare two different 401k loan rates, 10% and 50%.
You have the option to take out a $1000 401k loan which has only 1 payment due 1 year from now. 1 year from now, you will also have $1000 aftertax income to either pay back the loan or contribute to the Roth 401k.
Case 1 (don't take loan)
1 year from now, the 401k is worth $1080. You contribute $1000 to the 401k and your account is now worth $2080.
Case 2 (take loan, 10% 401k loan rate)
1 year from now, the taxable account is worth $1080 (10% return reduced by 20% marginal tax rate). You owe $1100 on the loan. You pay back the loan with $1080 from your taxable account and $20 from income, then contribute $980 to the 401k. Your account is now worth $2080.
Case 3 (take loan, 50% 401k loan rate)
1 year from now, the taxable account is worth $1080 (10% return reduced by 20% marginal tax rate). You owe $1500 on the loan. You pay back the loan with $1080 from your taxable account and $420 from income, then contribute $580 to the 401k. Your account is now worth $2080.
In this scenario, L doesn't factor into the decision. There was no difference between a 10% and 50% loan rate. Taking a loan results in the same outcome as not taking a loan. Does this follow from the decision tool I outlined?
L * T = 0, since the marginal tax rate on loan proceeds/repayments is 0%. They were 100% Roth. Also, 1  T = 1. All that matters is Rtax vs R401k since the other terms drop out. Rtax and Rtsp were equal in the example. In the end, there are no differences between the three cases.
If T is supposed to be the current marginal tax rate, then what formulas would you use to make the decision?
You have the option to take out a $1000 401k loan which has only 1 payment due 1 year from now. 1 year from now, you will also have $1000 aftertax income to either pay back the loan or contribute to the Roth 401k.
Case 1 (don't take loan)
1 year from now, the 401k is worth $1080. You contribute $1000 to the 401k and your account is now worth $2080.
Case 2 (take loan, 10% 401k loan rate)
1 year from now, the taxable account is worth $1080 (10% return reduced by 20% marginal tax rate). You owe $1100 on the loan. You pay back the loan with $1080 from your taxable account and $20 from income, then contribute $980 to the 401k. Your account is now worth $2080.
Case 3 (take loan, 50% 401k loan rate)
1 year from now, the taxable account is worth $1080 (10% return reduced by 20% marginal tax rate). You owe $1500 on the loan. You pay back the loan with $1080 from your taxable account and $420 from income, then contribute $580 to the 401k. Your account is now worth $2080.
In this scenario, L doesn't factor into the decision. There was no difference between a 10% and 50% loan rate. Taking a loan results in the same outcome as not taking a loan. Does this follow from the decision tool I outlined?
L * T = 0, since the marginal tax rate on loan proceeds/repayments is 0%. They were 100% Roth. Also, 1  T = 1. All that matters is Rtax vs R401k since the other terms drop out. Rtax and Rtsp were equal in the example. In the end, there are no differences between the three cases.
If T is supposed to be the current marginal tax rate, then what formulas would you use to make the decision?

 Posts: 334
 Joined: Sat Mar 28, 2009 8:38 am
 Location: Brooklyn, New York
Re: The exact math behind using 401k loan to pay down debt
The intuitive way to understand why the current tax rate upon repayment of the 401(k) loan isn't important is to realize that whatever was done with the proceeds of the 401(k) loan  for example paying off a student debt  would have (if not for the 401(k) loan) had to eventually be repaid with aftertax dollars, taxed at the current rate. It isn't proper to charge that as a 'cost' of taking out the 401(k) loan.Ketawa wrote:For a simple example of why T should be the marginal tax rate in retirement on the 401k loan proceeds, consider a hypothetical where you have a 401k that is 100% Roth and 100% Roth makes sense in the future for you. Your marginal tax rate now is 20%. You can invest in a fixed income investment making 10% in taxable, or making 8% in the 401k. I will also compare two different 401k loan rates, 10% and 50%.
You have the option to take out a $1000 401k loan which has only 1 payment due 1 year from now. 1 year from now, you will also have $1000 aftertax income to either pay back the loan or contribute to the Roth 401k.
Case 1 (don't take loan)
1 year from now, the 401k is worth $1080. You contribute $1000 to the 401k and your account is now worth $2080.
Case 2 (take loan, 10% 401k loan rate)
1 year from now, the taxable account is worth $1080 (10% return reduced by 20% marginal tax rate). You owe $1100 on the loan. You pay back the loan with $1080 from your taxable account and $20 from income, then contribute $980 to the 401k. Your account is now worth $2080.
Case 3 (take loan, 50% 401k loan rate)
1 year from now, the taxable account is worth $1080 (10% return reduced by 20% marginal tax rate). You owe $1500 on the loan. You pay back the loan with $1080 from your taxable account and $420 from income, then contribute $580 to the 401k. Your account is now worth $2080.
In this scenario, L doesn't factor into the decision. There was no difference between a 10% and 50% loan rate. Taking a loan results in the same outcome as not taking a loan. Does this follow from the decision tool I outlined?
L * T = 0, since the marginal tax rate on loan proceeds/repayments is 0%. They were 100% Roth. Also, 1  T = 1. All that matters is Rtax vs R401k since the other terms drop out. Rtax and Rtsp were equal in the example. In the end, there are no differences between the three cases.
If T is supposed to be the current marginal tax rate, then what formulas would you use to make the decision?
Mule
Re: The exact math behind using 401k loan to pay down debt
So I guess I was thinking about the wrong things originally, I was thinking about the total tax cost. Agree that you only pay additional taxes on the loan interest.Ketawa wrote:You probably have to go back to the original thread for a longer explanation of why it's the tax rate in retirement. But it makes sense, because extra taxes are only paid on the small amount of loan interest (i.e. extra funds you have to put in your 401k to repay the loan), which is why it's L * T.
Let's say the loan interest is $1000. When withdrawn in retirement, with a 25% tax rate, you'll pay $250 in taxes and get $750 to spend. But if your tax rate during the repayment phase is 33%, you'll need to earn $1493 to pay that $1000 in interest. So are the additional taxes paid the $250 or the $493? That would determine the proper rate to use.
Re: The exact math behind using 401k loan to pay down debt
The additional taxes paid are the $250. $1000 in loan interest * 25% is similar to the L * T term.Kosmo wrote:Let's say the loan interest is $1000. When withdrawn in retirement, with a 25% tax rate, you'll pay $250 in taxes and get $750 to spend. But if your tax rate during the repayment phase is 33%, you'll need to earn $1493 to pay that $1000 in interest. So are the additional taxes paid the $250 or the $493? That would determine the proper rate to use.
You don't need to earn $1493 to pay the interest because you took the loan. The loan proceeds have not been taxed. You could pay the 401k loan now, paying less interest, or pay it off over time using the loan proceeds and its earnings to cover the full $1000 interest.
Re: The exact math behind using 401k loan to pay down debt
I guess I could be swayed that the right answer is L*T. Those are the additional future taxes you'll pay as a consequence of borrowing now. The alternative investment must compensate for this value.Ketawa wrote:The additional taxes paid are the $250. $1000 in loan interest * 25% is similar to the L * T term. I see now.Kosmo wrote:Let's say the loan interest is $1000. When withdrawn in retirement, with a 25% tax rate, you'll pay $250 in taxes and get $750 to spend. But if your tax rate during the repayment phase is 33%, you'll need to earn $1493 to pay that $1000 in interest. So are the additional taxes paid the $250 or the $493? That would determine the proper rate to use.
For a traditional 401k, not a Roth 401k:
You don't need to earn $1493 to pay the interest because you took the loan. Ok, so you don't need to earn $1493, you need to get $1000 in any manner. The loan proceeds have not been taxed. Agree. You could pay the 401k loan now, paying less interest, or pay it off over time using the loan proceeds and its earnings to cover the full $1000 interest. Those earnings will be taxed at the current marginal rate, not future rate.
Re: The exact math behind using 401k loan to pay down debt
For this reason, Rtax is aftertax earnings in the taxable account. If it would help to make it more explicit, someone could separate Rtax into two separate terms to make it clear that both tax rates matter in the analysis.Kosmo wrote:Those earnings will be taxed at the current marginal rate, not future rate.

 Posts: 2884
 Joined: Tue Apr 01, 2014 11:41 am
Re: The exact math behind using 401k loan to pay down debt
Two comments.
The mortgages are stated as being for investment properties, therefore the interest on these mortgages would be tax deductible, but the interest on the 401(k) loan would not be. I do note that a high income person cannot deduct losses on passive Real Estate, but these losses, if any, are carried over until the property is sold.
If this was a Roth 401(k), I think that this would be a great idea. For a high current tax bracket person dealing with investment loans and a regular 401(k), no.
Ralph
The mortgages are stated as being for investment properties, therefore the interest on these mortgages would be tax deductible, but the interest on the 401(k) loan would not be. I do note that a high income person cannot deduct losses on passive Real Estate, but these losses, if any, are carried over until the property is sold.
If this was a Roth 401(k), I think that this would be a great idea. For a high current tax bracket person dealing with investment loans and a regular 401(k), no.
Ralph
Re: The exact math behind using 401k loan to pay down debt
This is addressed earlier in the thread. Interest on the 401k loan is accounted for by the L * T term in the decision rule above. It's a small factor.ralph124cf wrote:Two comments.
The mortgages are stated as being for investment properties, therefore the interest on these mortgages would be tax deductible, but the interest on the 401(k) loan would not be. I do note that a high income person cannot deduct losses on passive Real Estate, but these losses, if any, are carried over until the property is sold.
If this was a Roth 401(k), I think that this would be a great idea. For a high current tax bracket person dealing with investment loans and a regular 401(k), no.
Ralph
Rtax is the taxadjusted earnings on a fixed income investment, whether it be taxadjusted interest rate for mortgage prepayments, interest rate on a loan that doesn't have taxdeductible interest like an auto loan, taxadjusted interest rate on a taxable fixed income investment, interest rate on muni bonds, etc. (One reason I didn't include the current marginal tax rate is that Rtax encompasses all these possibilities.)