Of course it matters! But it's not the only thing that matters, and different people have different preferences, so you never know...
I'm in my late 40's, and generally my preferred age range is 25-45, but I also know several very hot 50-something year old ladies...
I might even consider someone who's 60-something if the chemistry was there. However, I can't imagine much chemistry once she gets into her 70's. Once I'm in my 70's, I might feel differently.
I also feel awkward with teenagers... Just not my thing. I like the all growed up wimmins!
One thing I have noticed is that many of the older ladies will fib and shave a few years off their age. If she's 45 and says she's 39, some ladies can get away with it, but if she's obviously 45 and tries to pass for 27, that is a major turn OFF for me.
If a lady feels compelled to tell me her age, just tell me. I'm just another dirty old man. If she lies, it makes me wonder what else she's lying about...