Below is John Wesley on the principle expressed by Jesus in Matthew 25.40.*
“One of the principle rules of religion is to lose no occasion of serving God. And since he is invisible to our eyes, we are to serve him in our neighbor; which he receives as if done to himself in person, standing visibly before us.” — John Wesley.
We often think of our acts of piety—such as prayer, worship, etc.—as the way we serve God. We should continue to do such things, but we must remember that those acts benefit us far more than they benefit God because their main purpose is to strengthen our faith and draw us near to God so that we may ultimately serve God by serving our neighbor.
*Matthew 25.40: “And the king will answer them, ‘Truly I tell you, just as you did it to one of the least of these who are members of my family, you did it to me.” (NRSV)