This study proposes a two-stage glowworm swarm optimisation (GSO) algorithm for the economical operation of the inner plant of a hydropower station. Binary GSO and real-coded GSO (RCGSO) algorithms are applied with different types of encodings to solve the unit commitment sub-problem and the economic load distribution (ELD) sub-problem, respectively. Moreover, an improved dynamic patching mechanism is developed to avoid invalid calculations and enrich the diversity of the solutions. A luciferin transfer mechanism helps the algorithm escape the local optimum and a local research mechanism enhances the diversity of the solution space by selecting from among the derived solutions. The RCGSO algorithm uses a variable-step mechanism to avoid missing the optimal solution. In comparison with the genetic algorithm and particle swarm optimisation, the RCGSO is significantly robust and provides better solutions to ELD sub-problems. Numerical simulations exhibited the superiority of the two-stage GSO algorithm in terms of stably and quickly solving the economical operation problem of hydropower stations.