Breeding of goats and sheep for milk production shows positive dynamics in Russia. For effective breeding it is necessary to collect information on the composition of goat and sheep milk and the nature of correlations between its components in different breeds. The article compares infrared spectra of milk parameters of Alpine and Zaanen goats, Lacon and ostfriesian sheep breeds, obtained on the automatic analyzer CombiFoss 7 D. It was found that in the milk of Alpine goats the content of the mass fraction of fat, solids, palmitic, long-, medium-, monounsaturated and saturated fatty acids was significantly higher by 7.2 to 82.4 percent (p<0.001) than in the milk of Zaanen goats. The milk of Lacon sheep had higher levels of fat, protein, casein, solids, urea, myristic, medium-, short-, and saturated fatty acids, and fatty acid trans-isomers by 19.4 to 82.6% (p<0.001) than that of ostfriesian sheep; the latter had higher lactose content and lower differential somatic cell counts by 19.4% and 23.4% (p<0.01), respectively. In sheep milk, the level of mass fraction of fat, protein, casein, dry matter was on average 1.3 to 1.9 times higher than in goat milk, with the greatest advantage in the content of monounsaturated, short-chain and polyunsaturated fatty acids, which is important for functional human nutrition. Calculation of correlation coefficients revealed both general patterns and individual differences in the relationships between goat and sheep milk components. Common were a high functional relationship between protein and casein B content; high positive relationship between fat and TS, fatty acids (r=0.61 and 0.96, respectively); high and medium positive relationship between saturated (SFA, LCFA, MCFA, myristic acid, palmitic acid) and unsaturated (MUFA, PUFA, SCFA, oleic acid, stearic acid) fatty acids (r=0.40 and 0.99); somatic cell count and differential cell count (r=0.36 and 0.33). The differences consisted in a weak positive relationship between urea, oleic acid and long chain fatty acids in goat milk while there was no relationship in sheep milk; between stearic acid there was a weak positive relationship in goat milk while there was a weak negative relationship in sheep milk; between lactose and long chain fatty acids there was a medium positive relationship in goat milk while there was a weak negative relationship in sheep milk.