Americans desire to end the war, y forcing Hitler to give up.
Hitler was very motivated during the war, so the only thing possible to get him to stop, would be to destroy his most important ally in the Pacific, Japan.
And it was successful, as shortly after the bombing, Hitler’s army surrendered and Hitler shot himself.
The bombings were horrible as many people died, but it was necessary to stop a brutal war, that would have likely killed much more people beyond the amount already killed.