grave concern to all nations," Obama said in a statement.
"The danger posed by North Korea's threatening activities warrants action by the international community," Obama said.
His comments echo those from capitals around the world, many of which rushed to condemn North Korea after it said it had detonated a nuclear bomb early Monday.
The test came despite international pressure on Pyongyang to rein in its nuclear program after years of disarmament talks and is likely to deepen the diplomatic stand-off.
United Nations Security Council members are expected to meet in an emergency session later Monday to discuss the test.
US top military officer, Admiral Mike Mullen, described an "increasingly belligerent challenge from North Korea," adding there was no reason to disbelieve the Asian nation's claim it carried out the test.
"While it will take us a couple of days to verify this test, certainly there's no indication that it wasn't as they say," Mullen told CNN.
The communist state tested an atomic bomb for the first time in October 2006 and a long-range rocket in April. It had threatened another nuclear test after the UN Security Council censured it for the rocket launch.
North Korea announced the latest test soon after the US Geological Survey reported a magnitude 4.7 seismic event in the proximity of the site of North Korea's first nuclear test.
It also coincided with the celebration in the United States of Memorial Day, which is dedicated to the memory of Americans who gave their lives in various conflicts, including the 1950-1953 Korean War.
South Korea's Yonhap news agency said the North also appears to have test-fired a short-range missile Monday from its launch site at Musudan-ri near Kilju.
Obama warned Pyongyang that its attempts to build a nuclear arsenal would only contribute to its further isolation.
"North Korea's attempts to develop nuclear weapons, as well as its ballistic missile program, constitute a threat to international peace and security," he said.
"By acting in blatant defiance of the United Nations Security Council, North Korea is directly and recklessly challenging the international community," Obama said.
"North Korea's behavior increases tensions and undermines stability in Northeast Asia. Such provocations will only serve to deepen North Korea's isolation."
He said North Korea "will not find international acceptance unless it abandons its pursuit of weapons of mass destruction and their means of delivery."
A US State Department official said the United States has begun consultations with its allies about North Korea's claim and a course of action.
China, Japan, Russia, South Korea and the United States have been negotiating since 2003 to persuade the North to abandon nuclear weapons in exchange for energy and security guarantees.
The negotiations led to a 2007 agreement under which the North said it would dismantle its nuclear facilities. The deal bogged down last December over verification.
In April, the North outraged the international community with a long-range rocket launch, a move that many nations said was actually a ballistic missile test.
After the UN Security Council condemned the launch and tightened sanctions, the North vowed to conduct a second nuclear test as well as ballistic missile tests unless the world body apologized.
It also announced that it was quitting the six-way talks, which are hosted by its closest ally China, and would restart its plutonium-making program.
However, Obama stressed that his administration will continue working with allies and partners in the six-party talks as well as other members of the UN Security Council to resolve the new nuclear crisis.
The impact of the test was felt on world money markets, despite light trading thanks to holidays in the United States and Britain, with the dollar firming against the yen and the euro as traders rushed to the safe-haven Us currency.