Microclimate modelling in a greenhouse is complicated due to the model’s irregularity and uncertainty of variable parameters. Evaluating the greenhouse’s changing climate is challenging since the conditions are always changing. As a result, it is necessary to determine the best way to manage the microclimate for the healthy development of growing plants. In order to maximise the growth of blooming plants, a modified leader optimisation algorithm (MLA) is created in this study to control the inside environment of a greenhouse. The implementation is done using greenhouses with a double-span structure located in Punjab and Mohali in India. The recommended approach analyses a number of characteristics, including carbon dioxide (CO2) concentration, temperature, and humidity, to keep track of the greenhouse’s environment. The humidity, temperature and CO2 content of flowering plants are studied using the proposed method implemented using MATLAB tool. The evaluated parameters are compared to conventional techniques like Battle Royale Optimisation (BRO), Particle Swarm Optimisation Algorithm (PSO), and BAT algorithm (BAT). Cost and energy consumption are also calculated for both proposed and existing models. Additionally, for the microclimatic parameters, error metrics, including Mean Absolute Error (MAE), Maximum Absolute Error (MaxAE), Mean Square Error (MSE), Root Mean Square Error (RMSE), and Standard Deviation (STD) are analysed and compared with the conventional approaches. The comparative outcomes highlight the minimal error metrics of a suggested MLA for temperature, humidity, and CO2 levels in blooming plants. The result analysis proves that the proposed MLA model is better than the previous models for predicting the proper range of CO2 concentration, suitable temperature, and perfect humidity for flowering plants. This demonstrates the effectiveness of the proposed MLA approach compared to the established methods for developing blooming plants.