We derive accurate values of the orbital parameters of the close binary beta Cephei star lambda Scorpii. Moreover, we present the first determination of the properties of the triple system to which. Scorpii belongs. Our analysis is based on a time series of 815 high-resolution spectra, covering a timespan of 14 years. We find a close orbit of 5.(d)9525 days (e = 0.26) and a wide orbit of approximately 1082(d) days (e = 0.23). The orbital parameters of the triple star and a spectrum synthesis lead us to conclude that the system is composed of two early-type B stars and a low-mass pre-main-sequence star rather than containing an ultra-massive white dwarf as claimed before. Our proposed configuration is compatible with population synthesis. The radial velocity variations of the primary allow us to confirm the presence of at least one pulsation mode with frequency 4.679410 c d(-1) which is subject to the light-time effect in the triple system. A detailed analysis of the complex line-profile variations is described in a subsequent paper.