Melatonin exists in numerous living organisms including vertebrates, insects, fungi, bacteria, and plants. Extensive studies have been conducted on the physiological roles of melatonin in various plant species. In plants, melatonin seems to act in antioxidant protection, as a growth promoter, and in photoperiodism. However, the mechanisms by which melatonin carries out these roles remain unclear. We manipulated the endogenous melatonin content in tomato plants by modifying the metabolic enzyme indoleamine 2,3-dioxygenase (IDO). The OsIDO gene was isolated from rice (Oryza sativa) and characterized using 3-D homology modeling and reverse genetic approaches. The amino acid sequence of OsIDO showed high homology to the Ustilago maydis IDO. The 3-D model structure of OsIDO is composed of a small and a large domain. Transgenic tomato plants constitutively expressing the OsIDO gene exhibited a decrease in their melatonin content. Moreover, the number of lateral leaflets decreased in transgenic plants. Protein extracts taken from these plants showed activity degradation, demonstrating the function of OsIDO. These results suggest the involvement of IDO in plant melatonin metabolism and a possible role in plant leaf development.