I have been lurking around MadridMan and other Madrid sites for quite some time - but never posted. Here's my chance. I first went to Madrid as a student a long time ago and always dreamt of owning a piso - a piece of Madrid.
I started looking seriously around 1999 and bought a downtown piso (flat) in 2001. You can look at some web sites to get an idea - but you really have to be on the ground in Madrid to get anything done. A great web site is
Idealista.com , there you can search for many different options of the apartment you want. One thing to know about the real estate system in Spain is that each realty company will only show you listings that they have - unlike in the states, if you go to ReMax in the states for example, they will show you houses listed by Century 21 and others, etc. Not in Spain. This makes the work slow going. Also, most people in Spain hold realtors in pretty low regard. Many listings are without a realtor because nobody wants to pay a commission, etc. One reason for this is the commissions never seemed to be spelled out in advance. The seller will tell the realtor the price he wants then the realtor will get whatever he can and keep the difference.
I wanted a piso in the center, so I basically "hit the streets" with a cell phone looking for "For Sale" signs on the balconies. I walked around in the areas I wanted to be - and started calling. I saw a lot of nasty stuff for big money. But I then found just what I wanted - an "exterior" fourth floor piso, 100 sq.m., 3 balconies to the street. Prices have gone up a lot recently - but there is talk of a real estate "Burbuja" or bubble meaning they could come tumbling down - good for you...
Regarding financing, I was surprised to find out that if you have enough of a down payment you can get a loan in Spain without having a source of income in the country. I have a loan from BBVA ( a big bank over there) I would send you to my banker if you are really interested....
The center of Madrid is the most expensive, it does get much cheaper in the outskirts...
En fin, there is a lot more to know of course, but this is a start - if you have a specific question, I'll try to answer.