This study evaluates the feasibility of using simultaneous mass balances of different nutrients as a tool for optimizing feeding composition in anaerobic digestion. Different ratios, among them total chemical oxygen demand/total Kjeldahl nitrogen (TCOD/TKN) and soluble chemical oxygen demand/TCOD (SCOD/TCOD), were assessed. The TCOD/total volatile solids (TVS) ratio was 1.73 kg O2/kg TVS, while, with the exception of the sewage sludge, pig slurry and animal wastes, a linear relationship was established between phosphorus and nitrogen (0.06 kg P/kg TKN (R2 = 0.9045)). The study was applied to different mixtures of waste (cucumber, quince, tomato, strawberry waste, vinasse, glycerol, tomato plant, pig slurry, sewage sludge, fish waste, landfill leachate and viscera). The mass balance was performed for 50 mixtures chosen at random, containing three different wastes. After evaluating the theoretical optimal values determined by the mass balances, the most promising data were compared with the experimental results of the anaerobic co-digestion of one of the three waste mixtures. As predicted by the mass balances, the codigestion of glycerol, strawberry extrudate and fish waste (41:54:4 in VS) improved methane production to a maximum value of 0.308 m3 CH4/kg TVSadded for an organic loading rate of 0.62-4.26 kg TVS/m3·d. [ABSTRACT FROM AUTHOR]