"American combat troops are not going to be fighting in Iraq again," the U.S. president told a White House news conference after meeting his national security team to discuss the crisis.
A Reuters/Ipsos poll released on Thursday showed that Americans overwhelmingly oppose U.S. intervention in Iraq in the face of the Sunni insurgency.
Obama and his advisers outlined the steps the United States would take to help Iraq repel the insurgency, led by the Islamic State of Iraq and the Levant, or ISIL.
Obama said he would send up to 300 U.S. military advisers to support Iraqi security forces and create joint operation centers in Baghdad and northern Iraq to share intelligence and coordinate planning to confront the insurgents.
U.S. officials said the advisers would be special forces troops operating in 12-member teams in different parts of the country in non-combat roles. Defense Secretary Chuck Hagel said the commandos' task was to assess the situation on the ground and evaluate the state of the Iraqi security forces.
The special forces teams were expected to be located at Iraqi military headquarters or possibly embedded with units as small as brigades, which usually have several thousand troops.
Having U.S. advisers in Iraq would bolster the military's ability to develop the kind of intelligence needed to carry out targeted air strikes against the insurgency. Officials have said without better intelligence the United States would have difficulty executing an effective air campaign.
Obama said U.S. military forces had increased their intelligence-gathering flights over Iraq in recent days and would consider military strikes if necessary and the action would benefit U.S. national interests.
"We will be prepared to take targeted and precise military action if and when we determine that the situation on the ground requires it," Obama said, adding that he would consult with the U.S. Congress and leaders in the region before taking action.
U.S. officials said any strikes would not be conditioned on whether the Iraqi government takes steps to heal its sectarian rifts, despite Obama's earlier comments that he would not engage in military action until the government dealt with its divisions.
Obama's Republican critics used the announcement to castigate him for not negotiating a deal with Maliki to leave some U.S. troops in Iraq after U.S. forces withdrew in 2011.
House of Representatives Speaker John Boehner urged the administration to produce a comprehensive plan for dealing with violence across the region, not just in Iraq but in Syria and Yemen as well. Obama indicated he was working toward that goal.
"Rather than try to play 'Whac-A-Mole' wherever these terrorist organizations may pop up, what we have to do is to be able to build effective partnerships, make sure they have capacity," Obama said.
Senior administration officials indicated that direct U.S. military action might not be limited to Iraq and did not rule out pursuing ISIL across the border in Syria where it is fighting to overthrow President Bashar al-Assad.
"We don't restrict potential U.S. action to specific geographic states," one U.S. official told reporters. "The group ISIL operates broadly and we would not restrict our ability to take action if necessary to protect the United States."
Obama had told Congress on Monday the United States was deploying up to 275 military personnel to provide support and security for the U.S. Embassy and U.S. citizens in Iraq.
The United States also is flying F-18 attack aircraft launched from the carrier USS George H.W. Bush on missions over Iraq to conduct surveillance of the insurgents, a U.S. official said on Thursday.