Aiming at the problem that sparrow search algorithm(SSA) may fall into local optima and has slow convergence speed, a hybrid strategy improved Sparrow Search Algorithm(HSISSA) is proposed in this paper, and it is applied to feature selection and model optimization of intrusion detection. Firstly, the hybrid circle-piecewise map is proposed to initialize the population and improve the uniformity of the initial population distribution; Secondly, merging the spiral search method in the vulture search algorithm and Levy's flight formula to update the positions of the discoverer and the scouter respectively, to expand the population search range and enhance the search capability; Finally, simplex method and pinhole imaging method are used to optimize the position of sparrows with poor fitness and optimal fitness, to avoid stagnation in the population search and falling into local optima. The performance of the algorithm is optimized through the above methods. The algorithm is tested on 10 classical benchmark functions and combined with Wilcoxon rank sum test analysis to verify the effectiveness of the algorithm, which showed improvements in convergence speed and accuracy. Finally, it is applied to feature selection and model optimization of intrusion detection. On average, 7.6 features and 10.1 features are retained on the CIC-IDS2017 dataset and UNSW-NB15 dataset, respectively, and 99.5% and 96.01% accuracy are achieved. The number and accuracy of the optimized features are better than the original algorithm. For DenseNet and random forest models, HSISSA can achieve 99.34% and 97.22% accuracy after optimization, which improves the performance of the model, thus, the algorithm shows better performance than other algorithms.