1 Introduction

Water contamination by dyes, pharmaceutical residues, heavy metals, and pesticides, etc., has become an environmental issue of major concern and is receiving wide attention due to the range of hazards arising therefrom. These pollutants, because of their malicious and carcinogenic nature, can be hazardous to humans and ecosystem [1]. Among organic compounds, cationic dyes such as methylene blue (MB), malachite green (MG), and crystal violet (CV) are the prominent pollutants due to their extensive use as a coloring agent in textile, leather, paper, and pharmaceutical industries [2]. In addition, MG is also used in aquaculture industry due to its fungicidal and bactericidal efficacy. Previous studies have reported that the exposure to dyes may adversely affect human health causing anemia, skin disorders, permanent injury to the eyes, and renal blood flow [3]. Direct ingestion may trigger digestive disease and increased heart rate [4]. Therefore, for environmental and human health sustainability, the removal of dyes from the aqueous system is an urgent necessity.

Several treatment technologies, including electrochemical methods, photodegradation, membrane, coagulation, oxidation, and adsorption are commonly applied to remove dyes from wastewater. Among them, adsorption is an effective, economically efficient, and ecologically safe technique for the elimination of dyes from contaminated water. Utilization of an abundantly available solid waste biomass from different sources as a feedstock through conversion to valuables is one of the strategies set to achieve long-term environmental sustainability goals. Population increase, booming economy, and rapid urbanization have greatly accelerated the rate, amount, and quality of solid waste generation [5]. The production of activated carbon was favored by the utilization of solid waste namely, cow dung and chicken manure [6]. Commercially available activated carbon is a widely used carbon-based adsorbent for sequestering pollutants from water as it possesses various characteristics such as large surface area, excellent thermal stability, porous nature, and variable surface chemical composition. However, high generation cost by pyrolysis technique and regeneration cost limits its widespread applications [7]. Thus, the potential alternative for treating wastewater is hydrochar developed through hydrothermal carbonization technique (HTC).

Compared to pyrolysis, HTC has the ability to convert the wet feedstock to hydrochar with relatively high yield without prior dewatering and drying [8]. Other merits of the process are operational ease and limited pollution generation risks to the environment. In addition, hydrochar has a lower ash content, higher carbon recovery, and more surface oxygen-containing groups than the biochar produced by the pyrolysis technique [9]. Therefore, among the carbon-based adsorbents used in water decontamination, hydrochar, due the presence of many polar functional groups such as lactone, hydroxyl, phenol, and carboxylic (developed during HTC steps [10]) is the most attractive adsorbent. Many studies have been conducted on the use of hydrochar developed from coffee husk waste [11], bamboo-derived [12], corn stover [13], olive waste [14], sewage sludge and coconut shell [15], and carboxylate-functionalized hydrochar [16] for the removal of dyes from aqueous solutions.

Jackfruit (JF, Artocarpus heterophyllus) is a tropical plant species belonging to the family Moraceae (originally from India) [17]. Jackfruit is the largest tree-borne fruit in the world. Usually, JF reaches 10–25 kg in weight at maturity. JF peel (JP) is one of the under-utilized waste materials and 50% of JF is composed of fibrous rind and unfertilized floral parts. JP is rich in hemicellulose, cellulose, and lignin [18]. Also, JP presents a great potential for the removal of MB from aqueous solutions [18]. Sugarcane bagasse (SB) is one of the largest agro-industrial wastes, which consists of cellulose (45%), hemicellulose (28%), and lignin (18%)[19]. Over the years, a large amount of SB has accumulated due to the expansion of sugarcane crops. Therefore, SB (based on lignin) is suitable and economically attractive for dye removal [20].

Co-hydrothermal carbonization (Co-HTC) has recently emerged as a promising thermochemical technique that can enhance the physicochemical properties of hydrochar [21]. In this study, JP was blended with SB (in varied mass ratio) during Co-HTC to improve the physicochemical properties of hydrochar for the removal of MB, CV, and MG dyes from aqueous solutions. To the best of our knowledge, the Co-HTC of JP with SB has not been reported previously. The mass ratio of JP and SB was optimized by testing the MB adsorption on developed hydrochar samples and its yield. The optimized hydrochar sample (JP/SB@4:1) was characterized and its dyes (CV, MB, and MG) adsorption performance was tested by varying experimental parameters such as solution pH, equilibrium time, adsorbent mass, initial dyes concentration, and temperature. The adsorption kinetics, isotherm, and thermodynamics of the adsorption process were also investigated in order to optimize the process.

2 Experimental

2.1 Chemicals and reagents

Cationic dyes viz. crystal violet (CV: C25H30N3Cl) and malachite green (C23H25ClN2) were purchased from Sigma-Aldrich, USA, while methylene blue (MB: C16H18N3SCl) was procured from CDH, India. Hydrochloric acid (HCl, 37%), Nitric acid (HNO3; 69 – 71%), and sodium hydroxide (NaOH, 97.5%) were purchased from Merck, Germany. The deionized (D.I) water used during the experiments was collected by the Millipore Milli-Q water system.

2.2 Co-hydrothermal carbonization of food waste

Jackfruit peel (JP) and SB were collected from a local vegetable vendor in Riyadh. JP (through ball mill) and SB (through domestic mixer blender) were separately crushed to powder. Slurry was made by suspending JP and SB with 4:1 (w/w) ratio in 50 mL D.I water, finally transferred to 200 mL PTFE lining for hydrothermal carbonization (HTC) reaction at 498 K for 2 h under autogenous pressure condition. Thereafter, the reactor was cooled to room temperature inside an oven and a hydrochar sample (JP/SB@4:1) was collected. JP/SB@4:1 sample was washed with 100 mL of 1 M HCl solution to remove alkali and other impurities, thereafter washed to neutral pH (~ 7.0) with D.I water. Similar HTC conditions were applied for the preparation of other samples with varied JP and SB (w/w) ratios (Table S1). Among the developed samples, a sample (JP/SB@4:1) with the best results in the MB removal tests was selected for detailed dye adsorption studies.

2.3 Characterization

The surface morphology and elements present in the developed hydrochar samples were analyzed by high resolution-scanning electron microscopy coupled with energy dispersive X-ray analysis (HRSEM-EDX, LV-SEM; S-3500 N, Hitachi at 1.0–5.0 kV) and transmission electron microscopy (TEM, Leo 912A 8B OMEGA EF-TEM, Carl Zeiss, Germany, at 120 keV), respectively. X-ray diffraction (XRD, SmartLab, Rigaku) patterns of hydrochar samples were analyzed. Elemental content of pristine- and dye-saturated hydrochar samples were analyzed by X-ray photoelectron spectroscopy (XPS, theta probe-based system, Thermo Fisher Scientific). Chemical functionalities present over the surface of pristine- and dye-saturated hydrochar samples were tested by Fourier transform infrared spectroscopy (FT-IR, Nicolet 6700, Thermo Scientific).

2.3.1 Water decolonization experiment

Batch scale adsorption experiments were carried out. 1000 mg/L MB, MG, and CV stock solutions were diluted to make adsorbate solutions of required concentrations (20, 40, 60, 80, and 100 mg/L). A series of 100 mL Erlenmeyer flasks containing 50 mL of dye solutions of the desired initial concentration (Co) were equilibrated at room temperature (298 K) with 0.005 g of JP/SB@4:1 over a shaker at 100 rpm. At the desired contact time (t, min) or at equilibrium, solid/solution phases were separated through filtration. The residual dye concentrations were quantitatively determined by UV–visible spectrophotometer (Thermo scientific, Evolution 600, USA) at maximum absorption wavelengths (λmax) of 665, 618, and 590 nm for MB, MG, and CV, respectively. The percentage adsorption (%), adsorption capacity at equilibrium (qe, mg/g), and at contact time t (qt, mg/g) were determined by Eqs. 1, 2, and 3, respectively as:

$$\mathrm{Adsorption} \left(\%\right)=\frac{{(C}_{o}-{C}_{e})}{{C}_{o}}\times 100$$
(1)
$${q}_{e}=\left({C}_{o}-{C}_{e}\right)\times \frac{V}{m}$$
(2)
$${q}_{t}=\left({C}_{o}-{C}_{t}\right)\times \frac{V}{m}$$
(3)

where Co, Ce, and Ct are the initial, equilibrium, and at any specified time t concentrations of dyes in aqueous phase (mg/L), respectively. V is the volume of adsorbate solutions (L), and m is the mass of adsorbent (g).

The influence of initial pH (pHi) on MB, MG, and CV adsorption onto JP/SB@4:1 was examined by carrying out adsorption experiments at Co: 25 mg/L in a series of 100 mL Erlenmeyer flasks and adsorbate solutions pHi were adjusted between ∼2 and 9 by adding desired amounts of 0.1 M NaOH/HCl solutions.

Contact time (t) study for dye adsorption at varied Co: 20–100 mg/L was also carried out by varying time between 1 and 720 min. In addition, the effect of adsorbate concentrations (Co: 20–100 mg/L) on adsorption was studied at varying temperatures (T: 298–328 K). All the adsorption experiments were performed in triplicate and average values have been reported.

3 Results and discussion

3.1 Characterization of JP/SB@4:1

Figure 1a displays the FT-IR spectra of JP/SB@4:1 and MB/MG/CV–saturated JP/SB@4:1 adsorbent and the characteristic chemical functional groups along with their respective wavenumbers are presented in Table S2. These characteristic peaks provide enough evidences to support the successful development of JP/SB@4:1. After adsorptive binding of MB, CV, and MG over JP/SB@4:1 surface some peaks were appeared, increased in intensities, and/or shifted to lower wavenumbers. In detail, a peak at 1369 cm−1 was increased in intensity and shifted to 1357, 1324, and 1365 cm−1 after CV, MB, and MG adsorption, respectively, owing to the interaction of carboxyl group present on JP/SB@4:1 surface with –N(CH3)2+ group of dye molecules through electrostatic interaction [23]. A peak at 3441 cm−1 after MG and MB adsorption was decreased in intensity, while peak intensity after CV adsorption was increased. This suggests that hydroxyl group played a vital role during the adsorption process of dye molecules through hydrogen bonding interactions [23]. A peak at 1606 cm−1 was increased and shifted to 1582, 1594, and 1582 cm−1 owing to the interaction of aromatic rings present over JP/SB@4:1 surface with aromatic rings of CV, MG, and MB molecules, respectively, by π − π interaction. New peaks at 794, 792, and 791 cm−1 were appeared after CV, MG, and MB adsorption, respectively, which proves the successful adsorption of dyes on the JP/SB@4:1 surface [16, 23]. In addition, the peaks at 724, and 722 cm−1 were noticed after MG and CV adsorption onto JP/SB@4:1 surface, respectively. These characteristic peaks provide enough evidences to support the adsorption of MB, CV, and MG over JP/SB@4:1 surface.

Fig. 1
figure 1

FTIR spectrum (a), and XRD pattern (b) of JP/SB@4:1

The XRD patterns of JP/SB@4:1 are illustrated in Fig. 1b. Three characteristic peaks were observed at 2θ = 15.80°, 22.43°, and 34.59°, are indexed as (110), (200), and (004) planes [29]. These are the characteristic peaks for cellulose [30]. In addition, the occurrence these peaks in XRD patterns of JP/SB@4:1 affirmed that HTC temperature up to 230 °C was safe enough to preserve cellulose content in JP/SB@4:1. This also indicates incomplete carbonization of JP/SB@4:1 [31]. The XRD results are consistent with previous studies reporting the preparation of hydrochar from bamboo [25], and rice husk [30].

The morphology and elemental analysis of pristine- and dye-saturated JP/SB@4:1 was carried out by SEM–EDX analysis as presented in Fig. S1. The elemental analysis data is displayed in Table S3. As seen in Fig. S1a, the JP/SB@4:1 surface had some cracks with both rough and smooth patches and some pores. The elemental carbon (C: 49.2%), oxygen (O: 49.9%), and nitrogen (N: 0.9%) were detected over pristine JP/SB@4:1 surface (Table S3). After CV adsorption on JP/SB@4:1, the surface becomes smooth (Fig. S1b). However, the surfaces of MB and MG loaded JP/SB@4:1 were uneven and irregular, affirming that dyes were successfully adsorbed over JP/SB@4:1 (Figs. S1c and S1d). The dye-saturated JP/SB@4:1 surface showed an increase in C and N contents, while a decrease in O content was found (Table S2). This indicates that MB, CV, and MG molecules were successfully adsorbed onto the JP/SB@4:1 surface. The C content on CV-saturated JP/SB@4:1 surface was comparatively higher than that on MG- and MB-saturated JP/SB@4:1 surfaces. This might be due to higher C content in CV molecular structure compared to MG and MB. The elemental N content was comparatively highest on MB-saturated JP/SB@4:1. In addition, the elemental sulfur (S) was only observed on the MB-saturated JP/SB@4:1 surface.

The XPS spectra of pristine- and dye-saturated JP/SB@4:1 is illustrated in Fig. 2. According to the survey XPS spectra for JP/SB@4:1, three major peaks were observed at 284.72, 399.97, and 532.87 eV ascribed to C1s (76.37%), N1s (0.81%), and O1s (22.77%), respectively (Fig. 2a, Table 1). The deconvoluted C1s spectrum of pristine JP/SB@4:1 was fitted into three peaks at binding energies 284.68, 286.39, and 288.05 eV ascribed to C–C/C = C, C-O/C-N, and O-C = O, respectively (Fig. 2b) [32]. The high-resolution deconvoluted N1s spectrum of pristine JP/SB@4:1 presents three peaks, a peak at 399.05 eV was due to the pyridinic N bond, a peak at 400.04 eV was attributed to pyrrolic N bond, and a peak at 401.49 eV was assigned to quaternary ammonium ion (Fig. 2c) [33]. The deconvoluted O1s spectrum displayed peaks at 531.70, 532.75, and 533.40 eV corresponding to C-O, C = O, and O-C = O, respectively (Fig. 2d) [34]. After MB, CV, and MG adsorption, the N1s contents were increased to 1.67, 1.65, and 1.69%, respectively (Table 1). In addition, a new peak appeared at 164.55 eV attributed to the S2p in MB molecules was observed (Fig. 2e), which is in good agreement with reported literature [35]. These results suggested that MB, CV, and MG molecules were successfully adsorbed onto the JP/SB@4:1 surface.

Fig. 2
figure 2

Wide scan XPS spectra (a), deconvoluted C1s (b), N1s (c), O1s (d), and S2p (e) of JP/SB@4:1

Table 1 Element contents (%) before and after MB, CV, and MG adsorption on JP/SB@4:1 through XPS analysis

3.2 Dye adsorption experiments

3.2.1 Effect of pH

The ability of JP/SB@4:1 to adsorb cationic dyes (MB, MG, and CV) solutions of Co: 25 mg/L in pH range 2.2 – 8.8 at 298 K was studied (Fig. 3a). The adsorption capacities of MB, MG, and CV dyes on JP/SB@4:1 were increased from 58 to 159 mg/g, 69.5 to 156 mg/g, and 62 to 190.9 mg/g with increase in pH from 2.5 to 6.6, 2.2 to 7.6, and 3.1 to 8.3, respectively. Further rise in pH from 6.6 to 8.8 results no visible increase MB removal efficiency, while change in MG and CV dye solution color were witnessed above pH 7.6 and 8.3, respectively. This is due to the occurrence of reaction between the dyes and OH ions[36]. The lower uptake of dyes on JP/SB@4:1 under acidic conditions was due to the protonation of functional groups (-COOH,-NH,-OH) on the JP/SB@4:1 surface [37]. These protonated sites resulted in repulsion of cationic dyes. As the pH augmented, the adsorption process was enhanced owing to deprotonation of active adsorption sites present over JP/SB@4:1 surface which results in electrostatic attraction between cationic dyes ions and negatively charged functionalities present over JP/SB@4:1surface. Figure 3b displays the point of zero charge (pHPZC) of JP/SB@4:1. The pHPZC of JP/SB@4:1 adsorbent was 6.7. This indicates that JP/SB@4:1 surface was positively charged when the pH < 6.7 due to the reaction of hydrogen ions with surface active functional groups, and was negatively charged when the pH > 6.7 [38]. Therefore, the maximum adsorption capacities of MB (159 mg/g), MG (156 mg/g), and CV (190.9 mg/g) were observed at pH 6.6 and 7.6, and 8.3, respectively. Similar trend was reported by Wu et al. [39] for the adsorption of MB dye using polyethyleneimine modified magnetic porous biochar. Therefore, the pH values 6.6, 7.6, and 8.3 for MB, MG, and CV dyes were chosen as optimal pH values for the adsorption experiments.

Fig. 3
figure 3

pH plot for dyes adsorption on JP/SB@4:1 (a), and point of zero charge (pHPZC) plot of JP/SB@4:1 (b)

3.2.2 Effect of contact time at various concentrations

The influence of contact time on the adsorption of cationic dyes (MB, CV, and MG) at varied Co: 20–100 mg/L onto JP/SB@4:1 was studied. It has been observed that the adsorption of MB, MG, and CV dyes at Co: 20 mg/L on JP/SB@4:1 during the initial contact time of 30 min sharply increased to 87.8 mg/g (Fig. S2a), 58.7 mg/g (Fig. S2b), and 87.8 mg/g (Fig. S2c), respectively. A sharp increase during initial 30 min was due to the availability of a large number of active adsorption sites on JP/SB@4:1 surface. Thereafter, slows down, reaching equilibrium in 480 min. The equilibrium uptake capacities of dye on JP/SB@4:1 at Co: 20, 60, and 100 mg/L were 147.9, 209.3, and 252.4 mg/g for MB; 149.3, 465, and 629.7 mg/g for MG; and 148, 213.9, and 233.7 mg/g for CV, respectively. Overall, the observed equilibration time for dye adsorption at varied concentrations was 480 min. However, for MB and CV adsorption at Co: 100 mg/L, the equilibration time was 360 min. As illustrated in Fig. S2 (a–c), the adsorption uptake of MG on JP/SB@4:1 at varied concentrations was comparatively higher than MB and CV dyes. This may be due to the difference in the structure of each dye in terms of functional groups and molecular size. The large molecule of CV may hinder its binding to the JP/SB@4:1 surface. For MB adsorption, the positively charged sulfur ions of MB can bind with negative charge carboxyl groups present over JP/SB@4:1 surface. Thus, MB molecules occupy larger areas over the JP/SB@4:1 surface. This results in hindering the binding of additional MB molecules and thereby restricting MB adsorption over JP/SB@4:1 surface [40].

3.2.3 Effect of initial dyes concentration and temperature

The effect of initial dyes concentration on the adsorption process was investigated in temperature range: 25–55 °C. It is clear that the adsorption capacities of MB, MG, and CV dyes on JP/SB@4:1 at 25 °C were increased with increase in dyes concentrations from 20 to 100 mg/L as illustrated in Fig. S3 (a–c). At 20 mg/L, the adsorption capacities of MB, MG, and CV dyes on JP/SB@4:1 were found to be 114.9, 159.4, and 107.9 mg/g, respectively. The increase in initial concentrations of MB, MG, and CV dyes to 100 mg/L results a 115.75, 295.98, and 107.04%, increase in their adsorption capacities to maximum values of 247.9, 631.2, and 223.4 mg/g, respectively. This increase in adsorption capacities may be due to the high driving force for mass transfer [41]. Besides, the MB, MG, and CV dyes uptakes were increased with rise in temperature from 25 to 55 °C at varied concentrations. For increase in temperature from 25 to 55 °C, the adsorption capacities have increased by 33.24, 10.72, and 10.19%, to maximum values of 153.1, 176.5, and 118.9 mg/g for MB, MG, and CV dyes, respectively at 20 mg/L, indicating that the adsorption process was endothermic in nature. This may be due to the development of new adsorption active sites over JP/SB@4:1 adsorbent surface formed by the breakage of internal bonds present over JP/SB@4:1 surface at high temperature [42]. This also results in enhanced diffusion of MB, MG, and CV molecules, reinforcing their transport into the pores of the JP/SB@4:1 adsorbent [43]. Similar adsorption behavior was observed for MB adsorption on maleylated modified hydrochar [16], and magnetic composite of coffee husk hydrochar [26].

3.3 Adsorption modeling

3.3.1 Kinetic modeling

Non-linear pseudo-first-order (PFO) [44] and pseudo-second-order (PSO) [45] kinetic models were applied to describe the dye adsorption kinetics data over JP/SB@4:1 at varied Co values. The non-linear PFO and PSO kinetic model equations are presented by Eqs. 4 and 5, respectively as:

$${q}_{t}={q}_{e}(1-{e}^{-kt})$$
(4)
$${q}_{t}= \frac{{\mathrm{q}}_{\mathrm{e}}^{2}{\mathrm{k}}_{2}\mathrm{t}}{1+{\mathrm{q}}_{\mathrm{e }}{\mathrm{k}}_{2 }\mathrm{t}}$$
(5)

where k1 and k2 represent the first-order (1/min) and second-order rate (g/mg-min) constants, respectively.

The fitting of data for MB, MG, and CV adsorption onto JP/SB@4:1 were shown in Fig. S2 (a, b, and c) and kinetic parameters were given in Table 2. It was observed that the regression coefficient (R2) values for PSO model at varied Co: 20–100 mg/L were comparatively higher than R2 values for PFO model. In addition, the experimental adsorption capacity (qe,exp) and calculated adsorption capacity (qe,cal.) values for PSO model were nearer supporting the applicability of the PSO model for MB, MG, and CV adsorption on JP/SB@4:1. The fitting of PSO model to experimental data affirmed the adsorption of dyes on JP/SB@4:1occured through chemisorption mechanism which involves electron sharing or hydrogen bonding [47] Similar results were reported for MB and CV adsorption on TiO2@AS [45], and N-ACG: OOC – 3 [46], respectively.

Table 2 Kinetic parameters for dye adsorption on JP/SB@4:1

3.3.2 Isotherm modeling

The MB, MG, and CV adsorption data on JP/SB@4:1was modeled by non-linear Langmuir (LIM) [47] and Freundlich (FIM) [48] isotherm models. The non-linear LIM and FIM are given by Eqs. 6 and 7, respectively as:

$${\mathrm{q}}_{\mathrm{e}}=\frac{{q}_{m}{K}_{L}{C}_{e}}{{1+K}_{L}{C}_{e}}$$
(6)
$${R}_{L}=\frac{1}{1+{K}_{L}{C}_{o}}$$
(7)
$${\mathrm{q}}_{\mathrm{e}}={K}_{F} {{C}_{e}}^{1/n}$$
(8)

where qm (mg/g) is the maximum monolayer capacity, KL (L/mg) and KF ((mg/g) (L/mg)1/n) are the Langmuir and Freundlich constants, n is the adsorption intensity. RL is a dimensionless constant termed as separation factor. The fitting of experimental data to adsorption isotherms is presented in Fig. S3 (a–c) and Table 3 displays isotherm parameters. It was observed the isotherm fittings and R2 values from dye adsorption data were fitted well to LIM indicating that the MB, CV, and MG adsorption onto JP/SB@4:1 followed monolayer adsorption mechanism. Based on the Langmuir equation, the qm values for MB, CV, and MG adsorption on JP/SB@4:1 at 55 °C were found to be 326.79, 300.87, and 922.29 mg/g, respectively. These values were comparable or much higher than the recently reported values for MB, MG, and CV adsorption in the literature (Table 4) [49,50,51,52,53,54,55,56]. The obtained values for RL parameter were between 0.2158 and 0.4378, indicating that the MB, CV, and MG dye adsorption onto JP/SB@4:1 adsorbent was favorable. The increase in the values of KL and KF with increased temperature from 25 to 55 °C, suggested that the adsorption of MB, CV, and MG dyes were highly favorable at 55 °C.

Table 3 Isotherm parameters for dye adsorption on JP/SB@4:1
Table 4 Comparison of MB, CV, and MG adsorption performance on JP/SB@4:1 with different adsorbents

3.3.3 Thermodynamic modeling

The adsorption of MB, CV, and MG dyes onto JP/SB@4:1 was studied at various temperatures viz. 298, 308, 318, and 328 K and the thermodynamic parameters namely, Gibbs standard free energy change (ΔG°), standard enthalpy change (ΔH°), and standard entropy change (ΔS°) were evaluated by employing Eqs. 9, and 10 respectively as::

$$\Delta G^\circ =-RT lnKc$$
(9)
$$lnKc=-\frac{{\Delta H}^{0}}{RT}+\frac{{\Delta S}^{0}}{R}$$
(10)

where Kc = qe/Ce is the thermodynamic equilibrium constant, T is the temperature (K), and R is the gas constant. The values of ΔH° and ΔS° were estimated from the slope and intercept of the plots of ln Kc versus 1/T (Fig. S4 a–c). The thermodynamic parameters of MB, CV, and MB adsorption on JP/SB@4:1 adsorbent were summarized in Table 5. The negative values of ΔG° at various temperatures indicate that the MB, CV, and MG dye adsorption onto JP/SB@4:1 was thermodynamically favorable and spontaneous process. Besides, these values were increased with the increasing temperature, indicating a better adsorption performance at a higher temperature. The adsorption process was endothermic as the ΔH° values were positive. The ΔH° values for MB, CV, and MG dyes at Co: 20 mg/L were 24.30, 5.86, and 18.27 kJ/mol, respectively. These values were < 40 kJ/mol, indicating that the adsorption process was in physical adsorption range.

Table 5 Thermodynamic parameters for MB, CV, and MG adsorption on JP/SB@4:1

3.4 Comparative performance of JP/SB@4:1 with other adsorbents

The maximum adsorption capacities of JP/SB@4:1 toward MB, CV, and MG were 326.79, 300.87, and 922.29 mg/g, respectively at 55 °C, which was higher than that of the hydrochars derived from other biomass wastes displayed in Table 4 [56—63], Comparatively better adsorption performance exhibited by JP/SB@4:1 than other hydrochars might be due to the JP was blended with SB (in varied mass ratio) during Co-HTC which led to improving the physicochemical properties of hydrochar for the removal of MB, CV, and MG dyes from aqueous solutions. However, the suitability of potential adsorbent is assessment in term of efficiency, availability, and cost-effectiveness. In comparison, JP/SB@4:1 proved to be an effective and economical method for the removal of MB, CV, and MG from contaminated water as compared to other adsorbents.

3.5 Dye adsorption mechanism

Besides adsorption isotherm and kinetic modeling, the adsorption mechanism of dyes on JP/SB@4:1 was investigated through FTIR, and XPS analysis. According to the results of FTIR, C = O, COOH, and OH functional groups participated during the adsorption of MB, CV, and MG on JP/SB@4:1. In detail, a peak at 3441 cm−1 was decreased in intensity after MG and MB adsorption, while increase in peak intensity after CV adsorption was observed. This suggests that OH bond which present on the JP/SB@4:1 surface undergoes hydrogen bonding with nitrogen atoms present in dyes molecules [23]. In addition, a peak 1369 cm−1 was increased in intensity and shifted to lower wavenumbers (1357, 1324, and 1365 cm−1) after CV, MB, and MG adsorption, respectively. These shifts in wavenumbers were due to the interaction of carboxyl group present over JP/SB@4:1 surface with –N(CH3)2+ group of dye molecules by electrostatic interaction [23]. A peak at 1606 cm−1 was increased and shifted to 1582, 1594, and 1582 cm−1 owing to the interaction of aromatic rings with JP/SB@4:1. Beside new peaks were appeared after CV, MG, and MB adsorption which proves the successful adsorption of dyes on the JP/SB@4:1 surface [16]. According to XPS analysis, the contents of N1s in JP/SB@4:1 (0.81%) were increased to 1.67%, 1.65%, and 1.69% after the adsorption of MB, CV, and MG onto JP/SB@4:1, respectively (Table 1). In addition, a new peak appeared at 164.55 eV attributed to the S2p in MB molecules (Fig.2e). On a whole, the mechanism that might happen during the adsorption of MB, CV, and MG dyes are presented in Fig. 4. According to thermodynamic results, a lower value of ΔH° indicates that the adsorption mechanism is a physical process. Therefore, the possible mechanism of MB, CV, and MG dye adsorption onto JP/SB@4:1 includes electrostatic interaction, hydrogen bonding, and π-π/n-π interactions.

Fig. 4
figure 4

Schematic representation of dyes adsorption mechanism on JF/SB@4:1

4 Conclusions

Current study reported the blending of food wastes (JF and SB) powders in 4:1 weight ratio and thereafter Co-HTC carbonizing it to develop JP/SB@4:1. JP/SB@4:1 was characterized through FTIR, XPS, SEM, EDX, and XRD and tested for the removal of MB, CV, MG dyes from aqueous environment. Results exhibits excellent adsorption performance JP/SB@4:1 toward MB, CV, and MG molecules. The equilibration time during dye adsorption was reached in 360 min at pH values 6.6 for MB, 7.6 for MG, and 8.3 for CV and temperature 328 K. The PSO and LIM were the best fitted models to the adsorption data. The qm values of 326.79 and 300.87, and 922.29 mg/g for MB, CV, and MG, respectively, were observed at 328 K. Thermodynamic parameters exhibited that the adsorption process is feasible, spontaneous, and endothermic. The dye adsorption mechanism involves electrostatic interaction, hydrogen bond interaction, and π-π/n − π interaction. Overall, results indicated that JP/SB@4: is a promising adsorbent in the removal of dyes from aqueous solutions.