Agricultural waste, such as walnut shells and sawdust, is becoming an increasingly important renewable resource in modern industries, helping to decrease reliance on traditional raw materials. Utilizing these byproducts in the production of composite materials enhances environmental performance and reduces carbon footprints. Furthermore, integrating walnut shells or sawdust with polymers significantly improves the balance between the mechanical properties and environmental sustainability of the final product. In this study, agricultural waste materials, specifically walnut shells and teak wood sawdust, are used as additives in wood-plastic composites. These materials were incorporated at weight percentages of 20%, 30%, and 40%, and different particle sizes of 1.5-1 mm, 1-0.8 mm, and 0.8-0.6 mm were employed to determine the optimal composite with the best mechanical properties for potential conversion into foam. High-density polyethylene (HDPE) served as the base material, with varying percentages of polycarbonate (PC) added (0%, 7.5%, and 15% by weight) to assess its impact on the final product. Additionally, 4% maleic anhydride-modified polyethylene (MAPE) is employed as a binder. The foaming agent azodicarbonamide was used at 1, 1.5, and 2 wt% with injection temperatures of 185, 190, and 195 °C. The study analyzed data using the Taguchi design of experiments (DOE) technique in injection molding. Additionally, a multi-criteria decision-making (MCDM) method is employed to determine the optimal model through practical experiments. The mechanical properties, including tensile strength, flexural strength, and impact strength, are analyzed in detail. The results for the teak sawdust composites were mixed. The highest tensile strength was 31.83 MPa, the highest flexural strength was 45 MPa, and the impact strength was 26.88 kJ/m². For walnut shell composites, the highest tensile strength is 34.34 MPa, the highest flexural strength is 33.123 MPa, and the best impact strength is 31.795 kJ/m². After conducting MCDM analysis, it was determined that the optimal composite for teak sawdust was TL3 (0% PC, 40% Teak sawdust, and 0.8-0.6 mm particle size), while for walnut shells, the best composite was WL1 (0% PC, 20% Teak sawdust, and 1.5-1 mm particle size). The foaming results revealed that teak composites had the highest tensile strength (32.16 MPa) and flexural strength (51.25 MPa), while walnut shell composites had comparable values. High-density polyethylene (HDPE) showed the highest impact resistance at 83.78 kJ/m². The addition of a foaming agent significantly enhanced the mechanical properties, with some values increasing by over 40%. These findings emphasize the importance of material selection and foaming technology in improving the performance of polymeric composites.