That will depend on whether you are still working for the employer or not. Some companies will not allow you to cash out your 401(k) plan while you are still employed. Rather, they will sometimes allow withdrawals due to a "hardship" or might even have loan provisions in the plan. If you are no longer employed, you can contact the plan administrator and request either a distribution or IRA rollover of the funds. Keep in mind that in most cases the money in your 401(k) has never been taxed. The only exception to this would be a Roth 401(k). If you have a traditional 401(k), you will need to be aware of the income tax liability and also potential penalties for early withdrawal. If you should have any further questions, please don't hesitate to reach out to me.
You will want to call up your plan provider and request a distribution. The number should be found on any statement or their online portal. Keep in mind there are potential tax penalties if it's an unqualified withdrawal (10%). Additionally, you will need to pay ordinary income tax on the distribution.