Fundamentals:
- Have a budget.
- Understand your currebt cashflow.
- Determine how much you can afford to pay per month without putting yourself at risk by drawing down your emergency funds or unacceptably cutting into your other expenses and investments.
Then remember that you want to put 20% or more down in cash, to avoid PMI, and recalculate with thatmajor chunk taken out of your savings.
Many banks offer calculators on their websites that can help you run these numbers and figure out how much house a given mortgage can pay for.
Remember that the old advice that you should buy the largest house you can afford, or the newer advice about "starter homes", are both questionable in the current market.
===========================
Added:
If you're willing to settle for a rule-of-thumb first-approximation ballpark estimate:
Maximum mortgage payment: Rule of 28. Your monthly mortgage payment should not exceed 28 percent of your gross monthly income (your income before taxes are taken out).
Maximum housing cost: Rule of 32. Your total housing payments (including the mortgage, homeowner’s insurance, and private mortgage insurance [PMI], association fees, and property taxes) should not exceed 32 percent of your gross monthly income.
Maximum Total Debt Service: Rule of 40. Your total debt payments, including your housing payment, your auto loan or student loan payments, and minimum credit card payments should not exceed 40 percent of your gross monthly income.
As I said, many banks offer web-based tools that will run these numbers for you.
These are rules that the lending industy uses for a quick initial screen of an application. They do not guarantee that you in particular can afford that large a loan, just that it isn't so bad that they won't even look at it.
Note that this is all in terms of mortgage paymennts, which means it's also affected by what interest rate you can get, how long a mortgage you're willing to take, and how much you can afford to pull out of your savings. Also, as noted, if you can't put 20% down from savings the bank will hit you for PMI.
Standard reminder: Unless you explect to live in the same place for five years or more, buying a house is questionable financially. There is nothing wrong with renting; depending on local housing stock it may be cheaper. Houses come with ongoung costs and hassles rental -- even renting a house -- doesn't. Buy a house only when it makes sense both financially and in terms of what you actually need to make your life pleasant. Do not buy a house only because you think it's an investment; real estate can be a profitable business, but thinking of a house as simultaneously both your home and an investment is a good way to get yourself into trouble.