In the present study, hydrogels are developed from carboxymethylcellulose, with the addition of cellulose nanofibers (CNFs) obtained from yerba mate stick residues and garlic oil. CNFs are obtained via physical (steam explosion), chemical (bleaching), and mechanical (ultrafine friction milling) processes. Garlic oil is encapsulated into sodium alginate for the evaluation of fungicidal potential. The samples are assessed for characteristics such as water absorption capacity (swelling) and inhibitory activity against Fusarium sp. FUS147 in vitro by Fourier-transform infrared (FTIR) spectroscopy, thermogravimetric analysis (TGA), and scanning electron microscopy (SEM). TGA and FTIR spectra confirm the cross-linking mechanism for citric acid in sodium carboxymethylcellulose (CMC) in the hydrogel formation. The incorporation of CNFs, sodium alginate, and garlic oil reduces the temperature at the beginning of thermal degradation, to 47, 38, and 31 °C, respectively, in relation to a hydrogel sample with only carboxymethylcellulose (HC). The swelling analysis reveals an increase of 57% for a sample with CNF, and 42% for a sample with incorporation of garlic oil encapsulated in alginate, in relation to the HC sample. The sample with encapsulated garlic oil shows a high degree of swelling with broad antifungal activity against the Fusarium sp. FUS147, showing great potential for use in agriculture.