They seem like one more bodily detail to tend to without much benefit, and sometimes more detriment (breaking a nail or scratching oneself up, ouch!).
Have you ever tried to scratch your balls with the tip of a hot dog?
Helps with grip, helps protect your delicate fingers, good for scratching and picking out lice and mites and so on. Useful when under attack.
They allow us to more precisely manipulate and feel with our fingertips by providing a hard surface to work against for the otherwise fleshy fingertips, and can themselves be used to pick at things smaller than fleshy nubs would be able to. That's not to say fleshy things can't be super precise and manipulable, but evolution doesn't work that way and we already have these grasping hands and not tiny worm fingers or something
Out ancestors had claws, and then they were reduced, because we didn't need them anymore.
You ever get a head scratch from someone with nice long fingernails? 🤤
Because fingernails (or early versions of it) helped our cladistic ancestors survive hundreds of millions of years ago, maybe more. Maybe it helped them find food or protect themselves, or some other reason that isn't so intuitive. Certainly they helped us (as humans) to survive, but the reason we have fingernails right now is just a happy accident.
Many people in this thread or conflating what we use them for today, right now, as reasons why we have them, which isn't exactly right. Certainly they are multifunctional, especially in a modern context, but that is not the reason why we have them. All these reasons posted in this thread remind me of Psychological Evolutionists that only use logic and intuition to find reasons to why we do things the way we do, but in reality it often just happens to be that way. There is no reason for evolution other then happenstance and happy accidents.
tl;dr - We didn't evolve fingernails to pick up dropped coins, our cladistic ancestors evolved them (likely many hundreds of millions of years ago) for some reason that I don't know. Maybe to dig things up or defence. Who knows. Any way we use them today is likely just a bonus.
P.S. I don't like using evolved as a verb, as if it was a conscious undertaking. It arguably isn't, not really.