As 401(k) plans are typically funded with pretax dollars, you will owe income taxes on the distributions out of the account. That said, you can manage the tax implications by choosing a withdrawal strategy.
You have up to four options in what to do with the account balance. You may be able to keep the money invested in your former employer's plan if the plan allows it. You can do an IRA rollover into a traditional IRA account. You can convert the 401(k) into a Roth IRA. Lastly, you could decide to cash in the 401(k) account balance.
If you roll the account balance over into a Roth IRA, or cash in the account, you'll owe income taxes on the total account balance in the tax year that you take this course of action. Cashing in doesn't make sense in managing your tax exposure, so let's rule that option out. Converting to a Roth IRA is a big upfront tax expense, but future distributions out of the Roth IRA are tax-free and the Roth IRA doesn't have the required minimum distributions, or RMDs, that a traditional IRA or 401(k) plan require starting in the year that you turn age 70½.
To minimize the tax bite out of a 401(k) plan or traditional IRA in retirement (after age 59½), you'll want to manage the distributions out of the account to meet your retirement income needs and any RMDs while managing the marginal federal income tax rate on your income.
The decision to pay the piper and convert the account balance to a Roth IRA can make sense if you don't expect to need the money for quite a while, or if you plan on passing the money on to the account beneficiary after your death.
Take a look at the big picture of what you want this money to help you accomplish in retirement, including estate planning goals, and work with a tax professional as needed.