If you want to purchase a home in the next 2 to 4 years, you should avoid bankruptcy if possible. However, for some people it’s a good way to “start over.” Just don’t file for bankruptcy unless you have addressed issues that led you to this point, or it was due to a one-time event that is not likely to recur. It's a big decision that could affect you for 7-10 years so consult an attorney and financial planner.