A liquid–gas interface (LGI) on submerged microstructure surfaces has the potential to achieve large slip velocities, which is significant for underwater applications such as drag reduction. However, surfactants adsorbing on the LGI can cause surface tension gradient against the mainstream, which weakens the flow near the LGI and severely limits drag reduction. The mechanism of the effect of surfactants on two-dimensional flows has already been proposed, while the effect of surfactants on the three-dimensional flow near the LGI is still not clear. In our study, we specifically design an experimental system to directly observe a three-dimensional backflow at the LGI. The formation as well as the behaviour of the backflow are demonstrated to be significantly influenced by the surfactant. Combining experimental measurements, theoretical analyses and numerical simulations, we reveal the underlying mechanism of the backflow, which is a competition between the mainstream and the Marangoni flows generated by the interfacial concentration gradients of surfactant simultaneously in streamwise and spanwise directions, reflecting the three-dimensional feature of the backflow. In addition, a kinematic similarity is obtained to characterize the backflow. The current work provides a model system for investigating the three-dimensional backflow at the LGI with surfactants, which is significant for practical applications such as drag reduction and superhydrophobicity.