Yes, rain can decrease the efficiency of neem oil. You need to re-apply it whenever it rains or when the infestation persists.
Neem oil doesn’t have a lasting residual effect, unlike other insecticides that’s why it is safe for beneficial insects.