Sunan Abi Dawud, Book 21, Hadith 86 (Abu Dawud 3175)

Narrated Jabir:

We were with the Prophet (ﷺ) when a funeral passed hi and he stood up for it. When we went to carry it, we found that it was a funeral of a Jew. We, therefore said: Messenger of Allah, this is the funeral of a Jew. He said: Death is fearful event, so when you see a funeral, stand up.