The drastic growth of waste biomass in the environment is an issue that needs to be addressed. From this perspective, thermochemical conversion methods are a vital alternative for transforming waste into useful solid products. Therefore, this research concentrates on an innovative method of producing biochar from Prosopis Juliflora plant through pyrolysis. The response surface methodology (RSM), in combination with the genetic algorithm (GA), is used to optimize input parameters of the pyrolysis process, namely weight and temperature, to obtain an increased yield rate of Prosopis Juliflora biochar (PJBC). Initially, the central composite design (CCD) model in RSM is used to construct the pyrolysis run order for PJBC production. The PJBC yield regression equation is employed as an optimization function, and GA is applied to determine the optimal input parameters of pyrolysis. The highest yield of 96.31% PJBC in GA optimization is obtained with optimized input parameters of 60 mg of Prosopis Juliflora burnt at 790 degrees C. The pyrolyzed PJBC was characterized by SEM, EDX, XRF, and FTIR, and the physio-chemical properties were measured. The characterization studies showed that PJBC has a Body-Center Cubic (BCC) structure, a crystallite size of 26.78 nm, and aromatic (C-H, bending vibration) and alkyne (C = C, stretching vibration) groups. This was shown by XRD and FTIR results. From the PJBC characterization results, it is understood that PJBC is a very suitable source for soil conditioning. Hence, it is further confirmed that optimizing the pyrolysis process variables produces the maximum PJBC yield from the Prosopis Juliflora plant. Therefore, using the PJBC efficiently would serve as an eco-friendly substitute for soil conditioning applications.