The Messenger of Allah ﷺ said, "Do not hate one another, do not envy one another, do not turn your backs on one another. Be servants of Allah as brothers. It is not lawful for a Muslim to shun his brother for more than three nights."
أن رسول الله ﷺ قال: لا تباغضوا، ولا تحاسدوا، ولا تدابروا، وكونوا عباد الله إخوانا، ولا يحل لمسلم أن يهاجر أخاه فوق ثلاث ليال.
Malik narrated it in Husn al-Khuluq (14) from Ibn Shihab, from Anas bin Malik, and he mentioned it. Bukhari narrated it in al-Adab (6076) and Muslim in al-Birr wal-Silah wal-Adab (2559), both of them through the route of Malik, with similar wording.