In this work, WO 3 -TiO 2 , chitosan-blended WO 3 -TiO 2 , and garlic-loaded WO 3 -TiO 2 nanocomposites were synthesized by the sol−gel and precipitation technique. The synthesized nanocomposites were characterized by XRD, FE-SEM, HR-TEM, EDX, UV-DRS, FT-IR, and TG-DTA analysis. The photocatalytic efficiency of the three synthesized nanocomposites on the degradation of dyes such as rhodamine B (Rh-B), methylene blue (MB), and methyl orange (MO) as organic pollutants was evaluated under solar light irradiation. The results show that garlic-loaded WO 3 -TiO 2 nanocomposites act as an excellent photocatalyst than chitosan-blended WO 3 -TiO 2 and WO 3 -TiO 2 nanocomposites. Further, the antimicrobial activity of the synthesized nanocomposites was examined against Gram-negative bacteria (Escherichia coli) by the well diffusion method. Garlic-loaded WO 3 -doped TiO 2 nanocomposites have demonstrated good antibacterial activity over chitosan-blended WO 3 -TiO 2 nanocomposites and WO 3 -TiO 2 nanocomposites. The possible reason may be the presence of organic sulfur compounds in garlic.