ABSTRACT Nearshoring is a phenomenon that has gained prominence in Mexico over the last 2 years, where companies have faced problems in meeting customer demand due to a service level and limited inventory space. Previous studies in aggregate planning did not consider the possibility of allowing rental of extra warehouse space if needed with a concurrent uncertainty in demand. Therefore, to address this gap in the research, an improved optimization model for multi-product and multi-period aggregate planning with uncertainty in demands given an area of inventory space is proposed. A set of cases based on real industry data were solved and compared to a model where no warehouse space is allowed to be rented. The results are improvements related to production costs and customer demand satisfaction. In addition, the model will help managers of manufacturing companies to determine the minimum inventory space required to effectively meet demand.