View the annual financial statements for the past few years and current business figures. Pay particular attention to how revenue, profit, liquidity and debt have developed. For example, a company can record profits but still have difficulty paying current invoices on time.
You should also review existing contracts, loans, lease liabilities and possible legal disputes. The liabilities you actually assume depend, among other things, on whether you buy the company itself or individual assets and business units thereof.