The present study aimed to investigate the flocculation efficiency in the harvesting of microalgae cultures, specifically Scenedesmus sp, Chlorella sp, Chlorococcum sp, and Teraselimus sp, cultivated in both freshwater and marine water. This investigation involved the addition of varying dosages (ranging from 0.1 to 100 mg/L) of the bioflocculant chitosan. The specific experimental conditions included a 30-minute treatment with 10 mg/L chitosan for Scenedesmus sp, a 60-minute treatment with 10 mg/L chitosan for Chlorella sp and Chlorococcum sp, and a 60-minute treatment with 100 mg/L chitosan for Teraselimus sp. The achievement of sedimentation efficiency was observed for 60 minutes while using a dose of 8.0 mg/L chitosan at a pH level of 8.0, as a consequence of the flocculation of all four algal biomass. The utilization of chitosan as a bioflocculant under alkaline circumstances resulted in the most significant documented recovery of microalgae. Moreover, the bioimaging assay conducted to assess cell viability provides evidence that the utilization of chitosan does not result in any detrimental effects on the four microalgae cultures, even when administered at elevated concentrations. Therefore, this method is regarded as an energy-efficient and cost-effective approach to biomass harvesting, offering an alternative to traditional approaches that include the use of chemical flocculants.