Shoptimizer is a web app that allows users to create a personalised grocery basket by adding items and quantities dynamically. It then compares the total basket cost across multiple supermarkets and identifies the cheapest option instantly. Users can view the price difference between stores and see how much they could save. The application also includes user registration and login functionality, enabling shoppers to save their basket history and reload previous baskets with one click. Instead of comparing individual items, Shoptimizer calculates full basket totals, providing a more meaningful and realistic comparison.

Shoptimizer was built using Streamlit for the web interface and navigation. We implemented session state management to track logged-in users and active baskets during use. JSON-based storage is used to securely store user accounts and basket history. Store inventory data is structured in dictionaries, allowing dynamic cost aggregation to compute basket totals for each supermarket. We also implemented legacy data handling to maintain compatibility with earlier storage formats. The architecture was designed to be modular and extensible.

One major challenge was managing persistent user data within Streamlit’s session-based environment. Ensuring that login state and basket state remained consistent across navigation required careful handling of session variables. Another challenge was designing a data structure that could scale while remaining simple enough to implement quickly. We also needed to ensure accurate matching between basket items and store inventory keys. Balancing functional depth with a clean, intuitive user interface was an ongoing design consideration.

We are proud of implementing a working authentication system alongside persistent basket history tied to individual accounts. The dynamic full-basket price comparison across multiple stores functions reliably and clearly highlights savings. We successfully handled legacy data migration and delivered a clean, usable interface within a short development timeframe. Most importantly, we transformed a common everyday task into a structured, automated comparison tool.

Future development could include split-basket optimisation to determine whether buying items across multiple stores yields greater savings. Additional features may include historical price tracking and visualisation, scraping of live prices from supermarket websites, interactive map integration, and price alerts for frequently purchased items. Shoptimizer provides a strong foundation that could evolve into a more advanced optimisation and price intelligence platform.

Built With

Share this project:

Updates