First determine where you want to buy. For foreign nationals, easy access or major cities are top choices. Second, since the prop would be leased out, a healthy rental market is a must - city with lots of job nearby, low crime rate, decent climate are all important factors to consider.
As for getting a mortgage loan, very few lenders lend to foreigners due to lack of local income and credit. It may still be doable but would probably require a bigger down payment, higher interest rate, and less favorable loan terms in general.
CA Real Estate & Mortgage Broker