The aim of this study was to assess the effect of substitution of dietary corn grain by dry citrus pulp or soybean hulls on energy and nitrogen partitioning, substrate oxidation, methane emission, and milk performance in dairy goats during midlactation. Twelve multiparous Murciano-Granadina goats of similar body weight (41.7 ± 2.8 kg) were split in 3 groups in an incomplete crossover design. One group of 4 goats was fed a mixed ration with 605 g/kg of dry matter of corn grain (CRG), another group replaced corn grain with dry citrus pulp (CTP), and the last with soybean hulls (SYH). The goats were allocated to individual metabolism cages. After 14 d of adaptation, feed intake, total fecal and urine output, and milk yield were recorded daily over a 5-d period. Then, gas exchange measurements were recorded by a mobile open-circuit indirect calorimetry system using a head box. Dry matter intake was similar for all 3 groups (1.53 kg/d, on average). Total replacement of the concentrate with fibrous by-products increased fiber apparent digestibility. The metabolizable energy intake was significantly greater for diet CRG than SYH (1,193 vs. 1,079 kJ/kg of BW⁰·⁷⁵, respectively), CTP showed an intermediate value. The heat production was higher for the fiber diet than starchy diet (908 vs. 843 kJ/kg of BW⁰·⁷⁵ for SYH and CRG, respectively). The efficiency of use of metabolizable energy for milk production obtained by regression was 0.59. Goats fed CTP and SYH diets produced similar CH₄ emissions (34.8 g/d, on average), significantly higher compared with goats fed the CRG diet (24.7 g/d). Goats of the 3 treatments were in negative energy balance, so the oxidation of fat was greater than for carbohydrates. No significant differences were observed for milk production (1.72 kg/d), and milk fat was significantly greater for a more fibrous diet compared with a starchy diet (6.57 vs. 4.95% in SYH and CRG, respectively).