I've done it - have fostered 7 cats so far (two pairs and three singles). Two of the three singles had serious health problems and I had them for the rest of their lives (2-3 years in both cases). The other five were healthy cats who in due course went to new homes - I had them from between two to five months.
Cat 1 - older female with mammary cancer, had been dumped at the vets, friendly cat, was v well for two and a bit years, then a few months of managing the spreading cancer and then PTS when the time was right.
Cats 2 and 3 - a semi-feral 12-week-old kitten who needed socialising, and her companion, a confident kitten about the same age. They went to a new home together after about four months
Cat 4 - eight-month-old kitten who grew up in rescue, total sweetheart. She had serious kidney problems, very well-controlled with diet for two years, then she suddenly went downhill and died within a week. That was the most traumatic, I had hoped she would live a lot longer.
Cats 5 and 6 - a mother cat found as a stray, and her five-month-old male kitten. Both a little timid at first, needed some socialisation, but no real issues. Went to a new home together after five months.
Cat 7 - older male from a difficult home situation. No health problems, extremely sweet and friendly - he was snapped up after two months.
So all quite different circumstances. Rescues also sometimes have opportunities to take a pregnant female or one with small kittens. The rescue pays vet bills and organises the vet trips if necessary, also provides at least some of the food and litter. My home situation (1-bed flat, no outside space) is not really any good for having a long-term cat but it's great to have them for a while. Saying goodbye is hard, but I know it's coming and can prepare emotionally. I suppose another issue is that I don't get to choose which cat I have! But I have loved them all.