Spread a 3-inch layer of compost or well-composted manure over a full-sun garden bed. Turn the compost into the top 8 inches of soil.
Dig the planting hole to the same depth and width of the nursery pot. Lift the dragon fruit plant out of the pot and place it in the hole. Fill in around the roots with soil and firm the surface lightly with your hands.
Erect a trellis at the time of planting. Install a 6- to 8-foot tall heavy post with a top cross beam that is at least 4-feet wide. Dragon fruit trellises have a T-shape and must be able to hold at least 100 lbs in weight.
Water dragon fruits after flowering when the top 2 inches of soil feels dry to the touch. Moisten the top 6- to 8-inches of soil. Do not water in spring as dry conditions are necessary to force the cactus into bloom.
Fertilize newly planted dragon fruits one month after planting and continue to fertilize every two months. Apply 1/4 lb of an 8-4-12 fertilizer per plant the first year. Gradually increase the amount to 6 lbs per plant over the next three years.
Prune away lateral stems along the trunk, and tie the trunk to the trellis post loosely with plant ties. Allow the lateral shoots to grow once the trunk reaches the top of the trellis, then train the lateral stems along the top crossbar. Tie them loosely in place.