Antenna arrays with high directivity, low side-lobe level, and null control in desired direction and whip antenna with wider bandwidth both need to be optimized to meet different needs of communication systems. A new natural heuristic algorithm simulating social behavior of grasshoppers, grasshopper optimization algorithm (GOA), is applied to electromagnetic field as a new effective technology to solve the antenna optimization problem for the first time. Its algorithm is simple and has no gradient mechanism, can effectively avoid falling into local optimum, and is suitable for single-objective and multiobjective optimization problems. GOA is used to optimize the side lobe suppression, null depth, and notch control of arbitrary linear array and then used to optimize the loading and matching network of 10-meter HF broadband whip antenna compared with other algorithms. The results show that GOA has more advantages in side-lobe suppression, null depth, and notch control of linear array than other algorithms and has better broadband optimization performance for HF whip antenna. The pattern synthesis and antenna broadband optimization based on GOA provide a new and effective method for antenna performance optimization.