Is there a word for feeling embarrassed for someone else?

It is a bit more complicated, though: German, as any other language, needed a word for that, and it needed it badly, but it did not have one until the mid-'90s, where it took it probably from the Spanish expression vergüenza ajena, which is a literal translation for fremdschämen. Here you have the dictionary entry for fremdschämen where they say they did not include this word until 2009.
The fact that people my age must have been witness to the introduction into the German language of this term combined with my observation that none of them remember this process, all swearing that this word has always been German, shows that the word was really badly needed. The adoption of this neologism has been nothing short of enthusiastic.