IPhone 4 replacement or repair?

I have an IPhone 4 which I'm quite attached to but it has a few problems- screen sometimes freezes, home button sometimes doesn't work and battery seems to die very quickly lately. I've had it a couple of years and was bought second hand so is it worthwhile getting it all repaired (would it work out expensive) or should I buy another same model? I know it's an older one but does everything I need it to.

Being the iPhone 4 is an older phone it would make more sense to get a newer iPhone.

Look around near you, ask how much it costs to get it repaired, but don't take one places' opinion, ask around local experts. If it proves too expensive, get a new one.

Dunno if apple (probably not but it's possible)does this but there are firms which produce devices that have a special chip that make it it stop working after a certain amount of time passes. It won't be specific, like e.g exactly 5 Years or we'd realize. If that's the case then, if you remove the chip, voila it acts like it always has, before it started going weird.