Global access to sanitary water is of utmost importance to human health. Presently, textile dye water pollution and cigarette pollution are both plaguing the environment. Herein, waste cigarette filters are converted into useful carbon-based adsorbent materials via a facile, microwave-assisted carbonization procedure. The cigarette filters are co-doped with phosphorus and nitrogen using ammonium polyphosphate to enhance their surface characteristics and adsorbent capability. The adsorbents are characterized physically to examine their surface area, elemental composition, and surface charge properties. Batch adsorption experiments were performed to determine the maximum adsorption capacity of the adsorbents. Additionally, the effects of various adsorption parameters— temperature, adsorbent dosage, pH, and time—on adsorption process were examined. The doped adsorbent showed a maximum adsorption capacity of 303.3 mg g− 1 respectively, which is three times that of the methylene blue adsorption capacity of commercially available activated carbon (~ 100 mg g− 1). Thus, the phosphorus and nitrogen co-doped carbonized waste cigarette filter adsorbent shows a profound potential as a sustainable solution to combat textile dye water pollution and cigarette filter pollution simultaneously, due to its low cost, simple preparation, and versatility in application.