WASHINGTON — The Trump administration considered imposing tariffs on imports from Australia last week, but decided against the move amid fierce opposition from military officials and the State Department, according to several people familiar with the discussions.

Some of President Trump’s top trade advisers had urged the tariffs as a response to a surge of Australian aluminum flowing onto the American market over the past year. But officials at the Defense and State Departments told Mr. Trump the move would alienate a top ally and could come at significant cost to the United States.

The administration ultimately agreed not to take any action, at least temporarily.

The measure would open yet another front in a global trade war that has pitted the United States against allies like Canada, Mexico, Europe and Japan, and deepened divisions with countries like China. It would also be the end of a reprieve for the only country to be fully exempted from the start from steel and aluminum tariffs that Mr. Trump imposed last year.

The White House declined to comment. But the Trump administration has fiercely criticized past administrations for making concessions on trade policy to accomplish foreign policy goals. Mr. Trump has said the approach has left the United States in the position of subsidizing the world, weakening American industry and pushing factories and jobs overseas, and has pledged to rework America’s trading relationships.