President Donald Trump has told the nation in a televised speech that the US military has nearly completed its goals in the Iran war.

He vowed to strike Iran extremely hard over the next two to three weeks and finish the job very fast, without setting any timeline for ending the conflict.

In his primetime address, Trump called for countries that receive oil through the Strait of Hormuz to show courage and seize the key waterway, which has been effectively closed by Iranian attacks since the conflict began.

The president is grappling with rocketing gas prices and sliding personal popularity ratings as the war continues into its fifth week and US midterm elections loom in November.

Wednesday night's speech did little immediately to reassure global oil markets that disruption to the Strait of Hormuz shipping route will ease anytime soon.

The price of benchmark Brent crude was trading at about $100 a barrel before the president started speaking. Afterwards it rose to $105.

In the 20-minute speech from the White House, Trump said the US was nearing completion of its core strategic objectives in the conflict, and had decimated Iran's navy drone and ballistic missile forces.

He stated, Very shortly, we are going to hit them extremely hard over the next two to three weeks, adding that if negotiations fail, the US will target Iranian energy infrastructure.

Trump indicated that he had refrained from attacking Iranian oil facilities to allow room for negotiation, mentioning that doing so would cripple Iran's ability to recover.

Earlier, Trump had claimed on social media that Iran requested a ceasefire, a claim that was quickly rejected by Iranian officials as "false."

The address, which elicited criticism from political adversaries, further provoked concerns about military strategies, particularly with a growing sentiment among Americans favoring a swift end to military engagement in Iran.

Recent polling indicates that a majority of Americans believe the war should conclude quickly, even at the cost of unfulfilled objectives. As the war evolves, both political and economic ramifications continue to emerge at the forefront of American consciousness.