Bankruptcy is tough, but is often the only alternative to get relief from piled-up debts. Most people file bankruptcy after significant financial events: divorce, serious medical condition, long-lasting loss of income, and many others. Some people manage to avoid bankruptcy, and to pay off or discard their debts by means of debt consolidation and foreclosure. This way, or another, both foreclosure and bankruptcy make most people think that they would not be able to become homeowners in the near future.How Bankruptcy and Foreclosure Affects Your CreditDespite the fact that bankruptcy helps you to forget about most, if not all, of your past debts, it leaves an ugly scar on your credit report that would not heal for the next 7-10 years. Most lenders try to stay away from lending money to people after bankruptcy, as they have a proof that a borrower had left other lenders empty-handed, using bankruptcy as legal shield from debt repayment.Foreclosure, while having a less negative effect, does not sound too promising for prospective lenders either, as they may see that you could not cope with scheduled monthly payments for whatever reason. As lenders would not foreclose for a couple of missed payments, foreclosure is a sign that you either had initially overextended yourself financially, or had a long-term cash shortage. Simply put, most lenders would decline your mortgage application after foreclosure or bankruptcy.Bad Credit Does Not Last ForeverThe fact that you filed bankruptcy or experienced a foreclosure does not mean the end to your homeownership dreams. Many people manage to buy a home shortly after bankruptcy or foreclosure. Very often, it does come at a higher price, as lenders who would undertake the risk of financing people with past negative marks would surely compensate it with higher interest rate and inflated charges. To avoid paying more in the long run, it is important to make every step you can to improve your credit ranking and to minimize the impact of your past bankruptcy or foreclosure on your credit score.Home Buying Tips For Bad Credit BorrowersWhile foreclosure and/or bankruptcy will haunt you for years, there are several things you can do to improve your credit ranking spend less money on your new home.First, you should reestablish history of timely payments. Getting a secured card from a major bank would help you to improve your credit score tremendously.Second, you should make a pause. The negative effects of bankruptcy and foreclosure tend to lessen over time. Instead of trying to apply for mortgage right after bankruptcy or foreclosure, wait a year or two. Your credit score will rise, allowing you to get better interest rate on your new mortgage.Last, you should perform a heavy research of subprime lenders. Despite the mortgage crisis in the recent years, many lenders continue to finance bad credit home purchases, especially since the home prices dropped. Therefore, seek all possible options to get a low-cost mortgage: find subprime mortgage lenders online, get loan quotes, and select the one that features the best terms.A bankruptcy or a foreclosure does not mean the end of borrowing. While obtaining a home loan with bad credit may be a significant stress, your bad credit would eventually go away, once you make timely payments on your new mortgage, allowing you to be more confident about your borrowing abilities again.