The vertical migratory behaviour of estuarine microphytobenthos, i.e. the biofilm-forming microalgae inhabiting intertidal sediments, is probably a significant factor for their success in this extreme and unstable environment. The present work aimed to assess the relative role of endogenous versus environmental control of benthic microalgal vertical migratory behaviour. This was done by comparing the patterns of vertical migration in undisturbed sediment samples kept under constant conditions of darkness and low light with those in ambient light conditions, by measuring the changes in the surface microalgal biomass during daytime low-tide periods. The results showed that the formation of a biofilm was a two-phase process. It began with a relatively small accumulation of cells at the surface, starting hours before the beginning of the light period and endogenously driven. However, the full formation of the biofilm required exposure to light by the expected beginning of the photoperiod, which further promoted upward migration and accelerated the cell accumulation at the surface. In the absence of light, upward migration was interrupted and the incipient biofilm began to disaggregate. The relative importance of the endogenously controlled behaviour varied during the spring-neap tidal cycle, reaching a maximum on those days when low tide occurred in the middle of the day, suggesting its entrainment by the duration of light exposure on previous days. The regulation of the surface cell concentration during daytime low tides was found to be strongly dependent on exogenous factors, particularly irradiance. The spontaneous disaggregation of the biofilm shortly before the end of the low-tide period (due to tidal flood or sunset), both under constant as well as ambient light conditions, suggested the presence of an endogenously controlled positive geotaxis.