The resilient modulus (MR) of various pavement materials plays a significant role in the pavement design by a mechanistic-empirical method. The MR determination is done by experimental tests that need time and money, along with special experimental tools. The present paper suggested a novel hybridized extreme gradient boosting (XGB) structure for forecasting the MR of modified base materials subject to wet-dry cycles. The models were created by various combinations of input variables called deep learning. Input variables consist of the number of W-D cycles (WDC), the ratio of free lime to SAF (CSAFR), the ratio of maximum dry density to the optimum moisture content (DMR), confining pressure (σ3), and deviatoric stress (σd). Two XGB structures were produced for the estimation aims, where determinative variables were optimized by particle swarm optimization (PSO) and black widow optimization algorithm (BWOA). According to the results' description and outputs of Taylor diagram, M1 model with the combination of WDC, CSAFR, DMR, σ3, and σd is recognized as the most suitable model, with R2 and RMSE values of BWOA-XGB for model M1 equal to 0.9991 and 55.19 MPa, respectively. Interestingly, the lowest value of RMSE for literature was at 116.94 MPa, while this study could gain the extremely lower RMSE owned by BWOA-XGB model at 55.198 MPa. At last, the explanations indicate the BWO algorithm's capability in determining the optimal value of XGB determinative parameters in MR prediction procedure.