We propose a solution to the menu planning problem adapting the bacterial foraging-based optimization algorithm. We design a mathematical model which satisfies the nutritional needs of individuals while enforcing the “Laws of Nutrition”, a set of postulates used by virtually all nutrition scientists in Latin America. This model corresponds to a constrained numerical optimization problem. We design a menu generator software prototype to set up a custom menu for 15 users with different characteristics. Results obtained by our proposal were satisfactory from an expert's point of view.