From The Dhamma Encyclopedia
A miracle (pàñihàriya) is an act or occurrence contravening the known laws of nature and which is believed to have a divine cause. The most commonly reported miracles include sudden non-medical healings, the appearances of deities, messages from deities etc. While the Buddha accepted the possibility of miracles he had a rather sceptical attitude towards most of the supposed miracles reported to him. Once somebody asked him to perform a miracle so that ‘even more people will have faith in you.’ The Buddha replied that there were miracles which thoughtful or skeptical people would have doubts about. There was however a miracle that all could have confidence in, what he called ‘the miracle of instruction’ (anusàsani pàñhàiya). This miracle consisted, he said, of teaching morality, acceptance, peace of mind and meditation (D.I,214).
See also: Psychic power
The value of miracles
Once a monk approached the Buddha and stated that he had been meditating for over 30 years.
The Buddha asked, "what have you learned?"
The monk replied, "I have mastered the jhanas and now I can walk on water." The monk proceeded to walk on water across a lake and then back.
The Buddha said, "Is there a boat that can take you across?" The monk said, "yes." The Buddha asked, "what is the cost to take the boat to the other side?" "One-and-a-half cents" replied the monk.
The Buddha replied, "Then the value of your miracles is one-and-a-half cents."
The Buddha continued, "you could have taken a boat across for one-and-a-half cents to the other side and spent your time developing vipassana [insight] instead; and by now you would have been enlightened."
The Buddha answers in a very practical and pragmatic way, for example what is the use of the miracle and is there a less time consuming alternative. Instead of being in awe at someone walking on water, like a naive person may have been, the Buddha just bluffs it off as nothing special.