Exodus 23:4-5

23:4 “If you encounter your enemy’s ox or donkey wandering off, you must by all means return it to him. 23:5 If you see the donkey of someone who hates you fallen under its load, you must not ignore him, but be sure to help him with it.

Deuteronomy 22:4

22:4 When you see your neighbor’s donkey or ox fallen along the road, do not ignore it; instead, you must be sure to help him get the animal on its feet again.