The drying process is a crucial stage in the thermal treatment of iron ore pellets in a straight grate, as it has a direct impact on pellet quality and energy consumption. Consequently, this paper develops a simulation model for the pellet bed drying process, which is validated through industrial data and enables the visualization of temperature and moisture distribution within the pellet bed. Based on the simulation model, an optimization model for the drying process is developed to minimize the specific energy consumption per tonne of green pellets. The constraints of the drying process are the moisture content requirements and burst temperature. A genetic algorithm is employed to optimize the parameters such as trolley speed, pellet bed thickness, air temperature, and air pressure. The results show that, with an absolute error criterion of 10 °C, the temperature calculation accuracy of the simulation model exceeds 86%, effectively describing the drying process in a straight grate sintering machine. Under yield limitations, the optimal cumulative energy consumption per tonne of green pellet is reduced by 1.50% during the drying process. Finally, a simulation and optimization system for the drying process in the straight grate is implemented in C++. This system not only generates essential data for designing the drying section in a straight grate but also lays a theoretical foundation for system optimization and optimal control.