Studies examining dual-task gait (DTG) have used varying conditions such as overground or treadmill walking, however it is not known whether brain activation patterns differ during these conditions. Therefore, this study compared oxyhaemoglobin (O2Hb) responses of the prefrontal cortex (PFC) during overground and treadmill walking. A total of 30 participants (14M/16F) were recruited in a randomized crossover study comparing overground and treadmill walking under single- and dual-task (STG and DTG) conditions. The DTG consisted of performing walking and cognitive (serial subtraction by 7′s) tasks concurrently. A portable 24-channel functional near-infrared spectroscopy system was placed over the PFC, corresponding the left and right dorsolateral PFC and frontopolar cortices (DLPFC and FPC) during overground and treadmill STG and DTG. Results showed a reduction in gait speed during DTG compared to STG on overground but not treadmill walking, while cognitive performance was maintained during DTG on both overground and treadmill walking. A reduction in O2Hb was seen in the FPC during DTG compared to a cognitive task only, and on the treadmill compared to overground walking. Increased activation was seen in the left and right DLPFC during DTG but did not differ between treadmill and overground walking. Our results support the concept of improved gait efficiency during treadmill walking, indicated by the lack of change in STG and DTG performance and concomitant with a reduction in FPC activation. These findings suggest different neural strategies underpinning treadmill and overground walking, which should be considered when designing gait assessment and rehabilitation interventions.