In civil engineering, the precise determination of pile bearing capacity holds paramount importance in ensuring foundations' safe and efficient design. The primary goal of this study is to develop innovative AI predictive models specifically tailored for the assessment of pile bearing capacity (PU). The fundamental predictive methodology adopted in this investigation is rooted in the Random Forest (RF) architecture. A unique hybrid technique has been applied to attain precise and optimal predictions, integrating the Giant Trevally Optimizer (GTO) and the Golden Eagle Optimizer (GEO). A dataset comprising 200 case histories derived from static load tests conducted on driven piles was utilized during the model construction and validation process. These datasets were employed throughout all stages of model development, including training, validation, and testing. The methodology applied in this study yielded precise results, emphasizing the efficacy of the proposed models. The incorporation of a hybridization technique into the RF model has resulted in dependable outcomes for predicting PU, thus significantly enhancing the performance of the traditional RF model. Optimizing the RF model with GTO optimizers produces reliable outcomes, substantiated by the R2 and RMSE values, which stand at 0.996 and 22.23, respectively.