In order to reduce repeated exploration and improve population diversity and spatial search ability of Flower Pollination Algorithm (FPA), a Flower Pollination Algorithm based on Neural Network optimization (NNFPA) was proposed. In the algorithm, an adaptive control factor was used to switch the global search and local search dynamically. The global search strategy of multi-party information was employed to speed up the convergence and maintain the diversity of pollen population, as well as reduce the dependence of population on social attributes in later iterations of the algorithm. The local search strategy based on neural networks was used to enable the algorithm to have memory function, so that the algorithm was able to have a stable search strategy, thereby reducing the uncertainty of the algorithm and allowing it to explore the solution space more fully. Nine common test functions and some functions selected from CEC2014 test set were chosen for simulation. The results show that compared with the standard FPA and the variant algorithm Flower Pollination Algorithm based on Hybrid Strategy (HSFPA), NNFPA achieves higher search accuracy and convergence speed on the chosen test functions. It can be seen that NNFPA has better optimization ability.