Hadithcore
Mishkat al-Masabih, 1932

Thauban reported God’s messenger as saying, “The most excellent dinar a man spends is one he spends on his family, one which he spends on his animal in God’s path, and one he spends on his companions in God’s path.” Muslim transmitted it.

وَعَنْ ثَوْبَانَ قَالَ: قَالَ رَسُولُ اللَّهِ صَلَّى اللَّهُ عَلَيْهِ وَسَلَّمَ: «أَفْضَلُ دِينَارٍ يُنْفِقُهُ الرَّجُلُ دِينَارٌ يُنْفِقُهُ عَلَى عِيَالِهِ وَدِينَارٌ يُنْفِقُهُ عَلَى دَابَّتِهِ فِي سَبِيلِ اللَّهِ وَدِينَارٌ يُنْفِقُهُ عَلَى أَصْحَابه فِي سَبِيل الله» . رَوَاهُ مُسلم

References1 variant
In-Book Reference
Book 6, Hadith 157