The effect of the addition of compatible solutes (ectoine and trehalose) on the denitrification process of saline wastewater was studied. In saline wastewater, it was observed that the initial concentration of nitrates was 500 mg N l−1. A fatty substance isolated from oiled bleaching earth (waste of vegetable oil refining process) was used as a source of carbon. The consortium, which was responsible for the denitrification process originated from the wastewater of the vegetable oil industry. The consortium of microorganisms was identified by the use of restriction fragment length polymorphism of 16S rRNA gene amplicons and sequencing techniques. It was noted that ectoine affects significantly the activity of lipase and nitrate reductase, and resulted in faster denitrification compared to saline wastewater with the addition of trehalose or control saline wastewater (without compatible solutes). It was observed that relative enzyme activities of lipase and nitrate reductase increased by 32 and 35%, respectively, in the presence of 1 mM ectoine. This resulted in an increase in specific nitrate reduction rate in the presence of 1 mM ectoine to 5.7 mg N g−1 VSS h−1, which was higher than in the absence of ectoine (3.2 mg N g−1 VSS h−1). The addition of trehalose did not have an effect on nitrate removals. Moreover, it was found that trehalose was used up completely by bacteria as a source of carbon in the denitrification process. The fatty acids were biodegraded by 74% in the presence of 1 mM ectoine.