Sayyiduna Abdullah bin Amr (may Allah be pleased with him) reports this saying of the Prophet (peace and blessings be upon him): "Whoever loves a man for the sake of Allah Almighty, Allah Almighty loves him too, and both of them will enter Paradise. The one who loves the other for the sake of Allah Almighty will be of a higher rank, and the one whom he loves for the sake of Allah Almighty will be joined to him."
Imam al-Tabarani recorded it.
Imam al-Bazzar also recorded it, and his wording is: The Prophet (peace and blessings be upon him) said: "Whoever loves a man for the sake of Allah Almighty and says: 'I love you for the sake of Allah Almighty,' both of them will enter Paradise, and the one who loves will be of a higher rank than the other, and the other will be joined to the one who loved for the sake of Allah Almighty." Its chain is hasan (good).
Hadith Referenceمجمع الزوائد ومنبع الفوائد / كتاب الزهد / 18015