Bacteria are known to form biofilms on various surfaces. Biofilms are multicellular aggregates, held together by an extracellular matrix, which is composed of biological polymers. Three principal components of the biofilm matrix are exopolysaccharides (EPS), proteins, and nucleic acids. The biofilm matrix is essential for biofilms to remain organized under mechanical stress. Thanks to their polymeric nature, biofilms exhibit both elastic and viscous mechanical characteristics; therefore, an accurate mechanical description needs to take into account their viscoelastic nature. Their viscoelastic properties, including during their growth dynamics, are crucial for biofilm survival in many environments, particularly during infection processes. How changes in the composition of the biofilm matrix affect viscoelasticity has not been thoroughly investigated. In this study, we used interfacial rheology to study the contribution of the EPS component of the matrix to viscoelasticity of Bacillus subtilis biofilms. Two strategies were used to specifically deplete the EPS component of the biofilm matrix, namely (i) treatment with sub-lethal doses of vitamin C and (ii) seamless inactivation of the eps operon responsible for biosynthesis of the EPS. In both cases, the obtained results suggest that the EPS component of the matrix is essential for maintaining the viscoelastic properties of bacterial biofilms during their growth. If the EPS component of the matrix is depleted, the mechanical stability of biofilms is compromised and the biofilms become more susceptible to eradication by mechanical stress.