<prompt> Human: My plan initially was to use about 32 of my salary to save for retirement while saving 1000 a month for a home in the next 5-10 years so a 60k-100k downpayment to hopefully have the home paid off with a 15 year loanHowever I am discovering:- that I do not know at my age where my job will take me- if I can borrow money from my 401kRoth IRAHSA to purchase a home if I decide toShould I be going balls to the wall on my retirement funds and living frugally until I am ready to buy a house, or should I save gradually, and when Im ready to buy the house just pull the trigger with money I have in a savings account?  <response>: saving 1000 a month for 5-10 years means you will have a 60-120k downpayment saved up. this meets your target of 60-100k downpayment.if you happen to need more of a downpayment, you can plan in advance by putting part of your retirement savings now in a Roth IRA. When making a withdrawal from a Roth IRA, the principal can be withdrawn tax penalty-free. Withdrawn earnings are subject to taxes penalty; earnings can be withdrawn tax-free if the account is at least 5 years old, and the first 10k of earnings can be withdrawn penalty-free if they are used toward the purchase of your 1st home.If your 32 retirement savings target is more than 18500 for 401k 5500 for IRA, you can put the rest in a standard taxable investment account. These funds can be withdrawn at any time penalty-free; you will owe on-going dividend tax each tax year, and capital gains tax when you withdraw.if at some point you think you will to need more liquid, you can adjust your retirement savings to put less in the 401k, more in the taxable account. 