Abstract Previous theoretical studies suggest that the topography along the west coast of Australia plays an important role in strengthening and trapping the Leeuwin Current (LC) at the coast. To isolate and quantify the effect of the continental shelf and slope on the LC and Ningaloo Niño, high-resolution (1/12°) ocean general circulation model experiments with different bottom topographies are performed. The “control” experiment uses a realistic bottom topography along the west coast of Australia, whereas the sensitivity (“no-shelf”) experiment uses a modified topography with no continental shelf and slope near the coast. The mean and variability of LC are realistically simulated in the control experiment. Compared to the control experiment, the strength of LC in the no-shelf experiment decreased by about 28%. The continental shelf influences the development of the 2010/11 Ningaloo Niño through modulating the LC variability: in August–October 2010 and January–February 2011, the LC in the control experiment is enhanced much more than that in the no-shelf experiment. As a result, the upper-50-m ocean temperature in the control experiment is about 26% warmer than the no-shelf experiment from September 2010 to March 2011. Different evolution of SST warming is also found in the two experiments. Comparisons of oceanic processes in the two experiments show that the shelf-slope topography can effectively trap the positive sea level anomaly at the coast in the control experiment while more Rossby waves radiate from the coast in the no-shelf experiment, resulting in a weaker LC.