Recently, a lot of renewable energy sources have been integrated into the distribution network. In consideration of economy and construction feasibility, some renewable energy sources are required to be installed in specific areas. In this paper, a bi-layer distribution network planning optimization model that considers the geographical restrictions of the installation locations of the substation, pumped storage plant, photovoltaic (PV) and wind power, as well as the impact of operation on planning, is proposed. In the planning optimization layer, the optimal distribution network topology with minimal total cost is obtained. The locations of the renewable energy sources and the substation are determined by the particle swarm optimization (PSO), and then all the components are interconnected using the dynamic minimum spanning tree (DMST) method. In the operation optimization layer, the economic operation strategy of the hybrid energy system with uncertainty is obtained by the scenario-based stochastic optimal power flow (OPF). The forecast error of the uncertain variable is represented by the probability distribution function, and the roulette wheel mechanism (RWM) is used to generate the stochastic scenarios. A modified 103-bus system is used to test the effectiveness of the proposed method, and the simulation results show that the proposed method can effectively reduce the total cost of the distribution network.