The paper compares different metaheuristics for using heat exchangers as a benchmark to estimate the best design parameter values using optimization efficient algorithms. Many MATLAB algorithms are used in this study. Also, an engineering equation solver, which is commercial software, is used to solve the issue. The design calculates three variables, which are the length, and inner and outer pipe diameter of the heat exchanger. The results showed that the best algorithms are particle swarm optimization, and when using this algorithm, the optimal design of the double pipe heat exchanger is as follows: the pipe length is 5.6734·10−1 m, the pipe inner diameter is 8.0203·10−3 m, and the pipe outer diameter is 2.2439·10−2 m.