Søren Kierkegaard said this quote

He who loved himself became great in himself, and he who loved others became great through his devotion, but he who loved God became greater than all.