The feeling that it's "sad" if a species dies out seems to be coming from an aesthetic point of view how the world should be. But is there a rationality behind it?
The only rational reason I was able to come up with is that more variety gives more possibilities for study. But this is only a weak argument I think and I hardly believe that this is the reason why most people would like to see these almost extinct animals protected.
And I don't even talk about killings here, or animals in physical pain. Take, for example, George, who died a few weeks ago. It makes me feel that people don't like these creatures to die because they don't want to die alone when they're old.
There are multiple reasons one might want to preserve animals from going extinct, not all philosophically based.
People tend to value what is scarce. (Whole books have been written on this.) A nearly-extinct animal is as scarce as you can get without being nonexistent: not only are there extremely few, but there is little hope of getting it back once it's lost. This is especially important if the animal is particularly cute or impressive (tigers, spotted owls, etc.).
Many people and much of popular culture lauds the protection of the weak and helpless. Although this does not appear to be as well-studied of a phenomenon, it seems to me to be fairly widespread.
An essential aspect of life is reproduction--leaving progeny much like yourself is in some sense what life is for (it is certainly why it is so abundant). In the absence of stated goals, one can thus identify survival of offspring as the most central goal of animals (possibly including us). Given the similarity between members of a species and the relative differences of other species, typically, survival of the species is a good proxy for survival of offspring since other members are pretty close. Thus, to the extent that we base our morality on mutually attainable interests, extinction is pretty much the worst thing that can possibly happen from the perspective of members of that species (well, except for extinction of the genus, family, order, etc..). Thus, if we are either empathic or non-speciesist, extinction of species scores very low on utility maximization and badly violates general rules, thus covering most frameworks for ethical behavior. (If we are speciesist and not empathic, there is no particular reason to care.)
Individual species don't matter so terribly much, but ecosystems do; if you can identify an individual species going extinct, there are probably many more also going extinct. If you can save the ones you notice, you are almost certain to also save adequate habitat for a bunch of species you don't notice. (This is the concept of flagship species.)
Biodiversity provides robustness and richness; the former is valuable if conditions change (in a different way than what was causing the extinction, obviously), while the latter provides more opportunities for us to learn, study, enjoy interactions, find drug targets, etc..
This isn't really an "answer"—just some contributing thoughts.
If psychological circumstance counts as "rational," then maybe it's that some of us feel a kind of respect for (or fear of) permanent change. For example, people die, but people are born; you may lose someone you love, but you may also gain another in time. This isn't the case with extinction. Maybe we, at some level in our brains, see extinction as a "more permanent" death than literal death itself, extinction being the death of a type and template, instead of a "mere" instance and copy. Therefore in the absence of compelling reason (whether to let perish or to save), we err on the side of caution and prefer to preserve what might never exist again.
Or, maybe for others, there exists a feeling of duty to protect the species, for example due to a generalized form of the golden rule: to treat others (including animals, provided their "form" is similar enough to trigger our compassion) as we'd like to be treated were we in their shoes (skins). This could be one of, I'm sure, many, ethical arguments.
If a species have faced competition from something else than humans and is about to go extinct we should not intervene, but most of the time we are to blame. We are also animals so in the long run we cannot be blamed for our faults, saving or not. Saving a species removes opportunity from another species.
If we were targeted by a pathogen that killed us like flies and spread like wild fire it would be an opportunity for lots of animals if we become extinct. We would not try to save it if we found a way to win no matter how much better that pathogen replicates than us.
The answer is obvious. One of the goals of sentient life is to work to correct the inherent unfairness of life itself. We were not given a utopia, we were given a puzzle. One aspect of the puzzle is unfairness. Most endangered species have become so by an unfairness.
We protect endangered species due to yet unaddressed unfairness in hopes that additional protections give us more time so that we can solve this bit of the puzzle before the lifeforms natural existance is terminated.