Regulation capability of an automatic voltage regulator (AVR) system still needs to be improved to keep the output voltage of the generator within the AVR system at the desired level. Researchers have been developing new control structures and designing controllers to improve the performance of the AVR system. Designing of PID controller, which is commonly preferred controller due to its simple structure and robustness against to system parameter changes, has an important place among these studies. Especially with the development of metaheuristic algorithms, more successful PID controller designs are emerging by using these algorithms than traditional design methods. Undoubtedly, the objective function utilized also has a significant effect on this success. Therefore, effects of the objective function in PID controller design process for an AVR system are examined in this study. Two different PID controllers are designed using two different metaheuristic algorithms, namely, crow search algorithm (CSA) and ant colony optimization (ACO) algorithm. The parameters of the PID controllers are optimally tuned by using five different objective functions in both algorithms. These objective functions are: Integral of absolute error (IAE), integral of squared error (ISE), integral of time-weighted absolute error (ITAE), integral of time-weighted squared error (ITSE), and a commonly used user-defined objective function. The performance of the designed PID controllers are compared in terms of transient response characteristics and performance metrics. In addition, in order to evaluate the stability of the AVR system with the designed controllers, bode analysis, pole-zero map analysis and robustness analysis are performed.