If you leave your job while you have an outstanding 401(k) loan, Uncle Sam now gives you extra time to repay it -- thanks to the new tax law. Getty Images By Kimberly Lankford, Contributing Editor February 13, 2019 QI heard that the new tax law changed the amount of time I have after leaving my job to pay back a 401(k) loan. What are the rules now for borrowing from your 401(k)?SEE ALSO: 8 Tax Deductions Eliminated (or Reduced) Under the New Tax Law AThe new tax law changed the deadline for repayment after you leave your job starting in 2018. In the past, you generally had only 60 days to repay the loan or else you’d have to pay income taxes on the money as if it was a withdrawal (and a 10% early-withdrawal penalty if you left your job before age 55). Sponsored Content But under the Tax Cuts and Jobs Act, you don’t have to pay taxes or the penalty if you repay the loan by the due date of your tax return for the year when you leave your job (including extensions). For example, if you leave your job in 2019, you’d have until April 15, 2020, to repay the loan (or October 15, 2020, if you file an extension). However, taking advantage of this extended time frame to repay could lead to complications if you’d like to roll over your 401(k) balance to a new employer’s plan, says Michael Weddell, director of retirement at benefits consultant Willis Towers Watson. You can generally borrow up to half of your 401(k) balance, but no more than $50,000. Most plans charge the prime rate plus 1 percentage point for the loan, which as of mid February would add up to 6.50%. You generally have five years to pay back the loan while you’re still working for that employer or longer if the 401(k) loan is to buy your primary residence. Most plans give employees 10 to 15 years to repay a loan for a primary residence, although some plans have deadlines as short as five years or as long as 30 years, says Weddell. Advertisement If you do take a 401(k) loan, try to keep contributing to your 401(k) while you’re paying back the loan so you can continue to receive any employer match and to minimize the hit to your long-term savings. You borrow your own money and pay the interest back into your account. But you will lose the opportunity for investment gains on the borrowed money while it’s out of the account. Just because you had to take a loan, Weddell says, is no reason to give up on saving for retirement and earning an employer match. SEE ALSO: Start Trimming Your 2019 Tax Tab Now Got a question? Ask Kim at email@example.com.