They are extracted using the steam distillation process. Under this method, the grounded spices and water is heated in the distillation flask and the steam is collected. The oil is separated from water using different compounds like diethyl ether and magnesium sulphate.