As an integral part of a STPV system, a solar absorber is essential to absorb most of the energy of the incident solar spectral irradiance. Metasurfaces have revolutionized contemporary research in optics and photonics and can benefit from the unique thermostable properties of refractory materials as well. We propose a metasurface-based solar absorber having a simple symmetric square-ring structure employing seven different refractory materials with an intent to boost the efficiency of the solar energy system. The proposed design exhibits broadband absorption for the visible regime and bears similarity to AM 1.5 solar spectral irradiance indicating the effectiveness of the design. The absorption is optimized in every case by varying the defining geometrical descriptors. The presented designs have in addition shown a high absorption rate over a range of incidence angles. Traditionally, the desired optical responses used to be obtained through electromagnetic simulation software by solving wave equation iteratively. This process spans hundreds of numerical calculations making it a time-consuming and computation-intensive strategy. Instead of following the classical numerical approaches for obtaining the EM responses, the data-driven intelligent approach based on machine learning is applied to predict the optical response. The algorithms including decision tree, K-nearest neighbor, linear and polynomial regression have been investigated for the due purpose of replacing the conventional simulations, with decision tree algorithm performing exceptionally fast and accurate. The trained models have shown an excellent predictability for broadband absorption (300–1200 nm), with MSE of the model equal to only 6.38 × 10−5 and R2 score of 0.9999. Further, we have trained the inverse model by employing a dimensionality reduction technique “PCA” on optical response vectors to predict the geometrical parameters of meta-atom yielding a min of 0.0 MSE and R2 score equal to 0.9999. The modeling procedure and numerical calculations are performed in a matter of seconds over the whole dataset especially when PCA with 10 components is applied. The presented approach bids a novel and effective methodology to speed up the on-demand design of intricate metasurfaces and optical structures for green energy applications.