The Westminster divines taught us the true foundation of the efficacy of the sacraments, and it is an important and biblical point. The first aspect of this is to note that they taught that the sacraments were efficacious. Their concern was to note why the sacraments were efficacious, not whether they were.
They made a point of saying that the efficacy of the sacrament does not depend on the subjective state of the minister—you are strengthened and nourished independently of my piety or intention in this. They also said that there is no inherent magical power in the elements—whether in the water of baptism, or here in the bread and wine.
So why are the sacraments efficacious? The sacraments are efficacious, they said, for worthy receivers—which is defined by faith alone, not works. This happens, they said, for two reasons. The first is the work of the Holy Spirit, who is present here with us. The second is the objective word of institution, which contains the promise of benefit. This promise of benefit is objective, it is biblical, and it is the offer of God. You are therefore summoned to respond to it in faith. Come and eat. Come and drink.