Abstract Wastewater treatment using aerobic granular sludge has gained increasing interest due to its advantages compared to conventional activated sludge. The technology allows simultaneous removal of organic carbon, nitrogen, and phosphorus in a single reactor system and is independent of space-intensive settling tanks. However, due to the microscale, an analysis of processes and microbial population along the radius of granules is challenging. Here, we introduce a model system for aerobic granular sludge on a small scale by using a machine-assisted microfluidic cultivation platform. With an implemented logic module that controls solenoid valves, we realized alternating oxic hunger and anoxic feeding phases for the biofilms growing within. Sampling during ongoing anoxic cultivation directly from the cultivation channel was achieved with a robotic sampling device. Analysis of the biofilms was conducted using optical coherence tomography, fluorescence in situ hybridization, and amplicon sequencing. Using this setup, it was possible to significantly enrich the percentage of polyphosphate-accumulating organisms (PAO) belonging to the family Rhodocyclaceae in the community compared to the starting inoculum. With the aid of this miniature model system, it is now possible to investigate the influence of a multitude of process parameters in a highly parallel way to understand and efficiently optimize aerobic granular sludge-based wastewater treatment systems.Key points• Development of a microfluidic model to study EBPR.• Feast-famine regime enriches polyphosphate-accumulating organisms (PAOs).• Microfluidics replace sequencing batch reactors for aerobic granular sludge research.