With resource shortages and global warming becoming increasingly serious, it is urgent to accelerate the transition to green and low-carbon energy. Wind power, as a kind of green, low-carbon, zero-cost renewable energy, has undergone rapid development. Aiming to address the problem of strong randomness and strong temporal correlations in wind power prediction (WPP), a new framework for WPP based on RF-WOA-VMD and BiGRU optimized by an attention mechanism is proposed. Firstly, the random forest algorithm (RF) is adopted to screen the influencing factors of wind power, effectively reducing the data redundancy and improving the prediction efficiency. Secondly, the variational modal decomposition (VMD) algorithm optimized by the whale algorithm (WOA) for WPP is adopted, which uses the WOA to adaptively determine the optimal parameters [K, α] in VMD, adaptively decompose raw wind power series, and reduce data noise. Furthermore, the BiGRU algorithm optimized by the attention mechanism is proposed for WPP. The attention mechanism is introduced to assign different weights to the hidden states of BiGRU to emphasize the impact of key information. Ultimately, the experimental result illustrated that the proposed model further enhances the prediction accuracy. According to data set 1, MAPE is reduced by 86.81% compared with BiGRU.