The correct term for tree worship is dendrolatry. In ancient India it was widely believed that sprits or gods inhabited trees, particularly large, old and gnarled ones, and tree worship was an important part of popular religion, as it still is. The Greeks had similar beliefs and called tree spirits dryads. In the Tipiñaka they are called rukkhadevatà, vanadevatà, or àràmadevatà (M.I,307; S.IV,302). Some trees, called wishing trees (rucarukkha), were believed to answer prayers, or more correctly, the spirits in such trees did this. Likewise, the healing power of certain herbs were believed to be due to the spirits that inhabited them. Before a woodsman cut a tree he would inform the resident spirit of his intentions and make offerings to it (Ja.I,442; IV,114).
There is no place in the Tipiñaka where the Buddha endorsed tree worship the way he occasionally did for worshiping gods. In the Dhammapada he said:`Gripped by fear people go to sacred, hills, woods, groves, trees and shrines. But these are not a safe refuge, not the best refuge. Not by going there is one freed from all suffering' (Dhp.188-9). He also said: `People generally believe that there is life (i.e spirits or gods) in a tree' (Vin.III,156), implying that while this was a widespread notion it was not one he accepted. Several Jàtaka stories poke fun at tree worship. See Bodhi Tree.