Membrane technology, a versatile alternative to traditional separation processes in industries and wastewater treatment, was employed in this study. Membranes were fabricated using cellulose acetate (C), dimethyl sulfoxide (D), and glycerol (G) at various weight percentages. To enhance membrane performance, a Magnetite@Xanthan gum nanocomposite (NC) was synthesized in-situ and analysed using FESEM-EDS. Experimental investigations incorporated the doping of the membrane with NC at different percentages (0 wt%, 0.1 wt%, 0.5 wt%, and 1.0 wt%). Increasing NC content resulted in smoother surfaces, improving anti-fouling characteristics, as confirmed by AFM. Integrating NC into the pure membrane reduced the contact angle, with 1.0 wt% Fe3O4@XG recording the lowest angle at 56.18°. Physical property analyses covered viscosity, pH, water uptake percentage, and porosity to assess the impact of NC integration. Under 5 atm pressure, the 1.0 wt% Fe3O4@XG membrane exhibited a substantial pure water flux of 3069.55 lit.m-2 h−1 compared to pure CDG. Furthermore, the 0.5 wt% Fe3O4@XG membrane displayed the highest flux recovery ratio (60.42%) compared to pure CDG (48.18%). A biodegradability test showed that the 1.0 wt% Fe3O4@XG membrane exhibited superior weight loss (43.75%) over 28 days. This research underscores the potential of these membranes for diverse applications, including wastewater treatment and sustainability.