When Joseph Smith went into the grove of trees near his home to pray, the question on his mind was “Which is the true church?” He was told to join none of them, that their creeds were an abomination, and that “they draw near to me with their lips, but their hearts are far from me, they teach for doctrines the commandments of men, having a form of godliness, but they deny the power thereof” (JS-H 1:19).
Keep in mind that the churches of Joseph Smith’s place and time consisted of Baptist, Presbyterian, and Methodist sects. Certainly many of the people who belonged to those churches did their best to love and serve the Lord, but the problem was their creeds. Specifically, although each of these Christian religions offered baptism and communion of some form, they denied that they were necessary for salvation or that they had an efficacy, insisting that salvation came through faith alone.
And so the Lord said that they practiced a “form of godliness” but denied the power of godliness, because the power of godliness–the power to become like God–is explicitly linked to the ordinances, including baptism, partaking of the sacrament, and the ordinances of the temple (See D&C 84: 20-22: “In the ordinances [of the priesthood], the power of godliness is manifest. And without the ordinances thereof, and the authority of the priesthood, the power of godliness is not manifest unto men in the flesh; For without this no man can see the face of God, even the Father, and live.”).
These ordinances are the ordained way that we are cleansed from our sins and gain power to refine and perfect our natures. As we become more Christlike in our thoughts, desires, and actions, we become more fit to endure His glory and abide in His presence.
Without these ordinances, it is impossible for us to become like God. And it is impossible for us to return to His presence.
That is the power of the temple; that is why it is so necessary to our lives. The temple teaches us and molds our hearts toward godliness. The temple makes it possible for us to go back to our Father in Heaven and live with Him forever.