This paper deals with the application of a multiobjective optimization algorithm that allows obtaining an almost sine waveform through a multilevel PWM modulation for a power converter of 17 levels of line voltage. The goal of this work is to achieve values of total harmonic distortion (THD) with levels very close to 0% in the first 50 harmonics, without affecting the root mean square voltage (RMS), keeping it at a desired value. To validate the performance of the algorithm, a cascaded multilevel power converter with H-bridges in common source topology was simulated, with an asymmetry of 1:3 ratio. The results allow verify the proper THD optimization of the first 50 harmonics keeping the RMS value of the output voltage constant.