Yes. However you will need a larger deposit. The length of time left on your visa will be critical to lenders agreeing a mortgage.