How to Create an Automated Grocery List from Excel Recipes using Power Query
Question details
The user wants to build a dynamic grocery list in Excel that automatically aggregates ingredients from selected weekly recipes, calculates total quantities, and categorizes the items.

- Product
- Excel
- Device & OS
- not provided
- Scenario
- Meal planning and generating a consolidated weekly grocery list based on user-selected recipes.
- Observed behavior
- The user needs a method to dynamically filter selected meals, combine duplicate ingredients, group them by category, and sum the required quantities into a final list.
Ensure your recipe data is organized into standardized Excel tables with consistent ingredient names and measurement units before attempting to automate the aggregation process.
Use Power Query to Automate the Grocery List
Power Query is the most robust tool for combining, grouping, and filtering ingredients from multiple recipe tables without complex formulas.
Power Query allows you to merge your weekly meal selections with your master recipe database. By grouping the output, it automatically sums up quantities for duplicate ingredients.
Select your Recipe data and Meal Selection data, press 'Ctrl + T' to format them as Excel Tables, and name them appropriately (e.g., RecipeTable, MealSelection).
Go to the Data tab on the ribbon, click 'Get Data', then select 'From Table/Range' to load both of your tables into the Power Query Editor.
In Power Query, select 'Merge Queries' to join the Meal Selection table with the Recipe table based on the Recipe Name column. This filters the data to only include ingredients for your selected meals.
Select the Ingredient Category and Ingredient Name columns, click 'Group By' on the Home tab, and set the new column to 'Sum' the Quantity column.
Click 'Close & Load' to output your automated grocery list into a new Excel worksheet.

Use Dynamic Array Formulas
If you prefer not to use Power Query, Excel's dynamic array functions can generate the grocery list in real-time.
Automate Your Meal Planning with WPS Spreadsheet
WPS Spreadsheet provides powerful data tools including dynamic arrays and advanced filtering to help you effortlessly consolidate recipes into an organized grocery list.
- 1. Open Your Recipe Workbook: Launch WPS Spreadsheet and open your existing recipe and meal plan workbook.
- 2. Utilize Data Consolidation: Navigate to the Data tab to utilize the 'Consolidate' or 'PivotTable' features for your ingredients.
- 3. Group and Sum: Select your recipe tables as the data source to automatically sum quantities and group ingredients by category.
- 4. Save in Standard Format: Save your automated grocery planner seamlessly in the standard .xlsx format to retain all functionalities.

Frequently Asked Questions
Why are identical ingredients not summing correctly in my automated list?
This usually happens due to inconsistent spelling, trailing spaces, or different measurement units (e.g., 'cup' vs. 'cups'). Ensure all ingredient names and units are exactly standardized in your source recipe tables.
Can I automatically sort my grocery list by supermarket aisles?
Yes. You can add an 'Aisle' or 'Category' column to your master ingredient list. When using Power Query or PivotTables, sort or group by this Aisle column first, followed by the ingredient name.
Do I need to rewrite the formulas every week for a new grocery list?
No. Once you set up Power Query or Dynamic Array formulas, you only need to update your weekly recipe selections. For Power Query, navigate to the Data tab and click 'Refresh All' to generate the updated list.
How do I handle different units of measurement for the same ingredient?
You will need to create a conversion reference table and use functions like VLOOKUP or XLOOKUP to convert all varying units to a standard base unit (like ounces or grams) before summing them up in your list.




