Extensive research and development have been dedicated to nano-reinforced polymer composites, owing to their exceptional physical and chemical properties. Recent studies have focused on quantifying the impact of nanofillers on the properties of these composites. Properties such as macroscopic thermal conductivity play a vital role in various engineering applications, including aerospace engineering, automotive industry, energy storage equipment, and electronic devices. The composition of the embedded polymeric filler in the composite matrix significantly influences the overall macroscopic properties of the material. However, previous studies primarily relied on deterministic models that disregarded uncertainties and did not account for the presence of uncertainties in these materials. Consequently, the predicted results deviated from the experimental findings. Moreover, the computational costs associated with stochastic multiscale modeling are high, prompting the use of alternative methods to propagate uncertain parameters across scales. With advancements in high-performance computing and artificial intelligence, machine learning has gained popularity as a modeling tool in numerous applications. Machine learning (ML) is often employed to construct surrogate models by establishing mappings between specific rules and algorithms to build input-output models using available data. ML models are particularly useful for nonlinear inputs, especially when sufficient data are accessible to establish robust relationships. In this study, we propose a stochastic multiscale approach based on ensemble learning to predict the macroscopic thermal conductivity of nanoreinforced polymer composites. We developed eight types of machine learning models: Multivariate Adaptive Regression Splines (MARS), Support Vector Machines (SVM), Regression Trees (RT), Bagging Trees (Bagging), Random Forest (RF), Gradient Boosting Machine (GBM), Cubist, and Deep Neural Networks (DNN). These models are integral to the stochastic modeling process, allowing us to construct representations of all uncertain input variables and the desired output parameterization, specifically the macroscopic thermal conductivity of the composite material. To find the global optimum and significantly reduce computational costs, we employ Particle Swarm Optimization (PSO) for hyperparameter tuning. We also conduct an analysis of the computational costs and model complexity, examining the advantages and disadvantages of each method. The results demonstrate that the proposed stochastic ensemble machine learning method, which considers uncertainties, exhibits excellent performance. This method plays a crucial role in computational modeling, aiding in the design of new composite materials for applications related to thermal management.