The move could heighten regional tension and deal a fresh foreign policy blow to US President George W. Bush ahead of mid-term elections. The White House branded the act "provocative" and said it expected the UN Security Council to take immediate actions.
Long Pyongyang's chief ally, China denounced the "brazen" act, urging it to avoid action that could worsen the situation, and Russian President Vladimir Putin also condemned the test. The US Geological Survey said it had detected a 4.2 magnitude tremor in North Korea at 10:35 local time (0135 GMT). The Japan Meteorological Agency said its data showed a tremor took place around Gifu, on the peninsula's northeast coast around 110km from the Chinese border.
Pyongyang's official Korean Central News Agency (KCNA) said there was no leak or danger from its test. "The nuclear test was conducted with indigenous wisdom and technology 100 percent," KCNA said. "It marks a historic event as it greatly encouraged and pleased the KPA (Korean People's Army) and people that have wished to have powerful self-reliant defence capability."
Analysts say North Korea probably has enough fissile material to make six to eight nuclear bombs but probably lacks the technology to devise one small enough to mount on a missile.
Unusual activities were detected in a rugged area in North Korea on Monday, causing South Korean authorities to suspect that the communist state might be preparing a second nuclear test, a news report said.
Kim Seung-Gyu, head of South Korea's spy agency, told parliament that activity involving vehicles and some 30 to 40 people was under way at Punggyeri in the northeastern county of Kilju, Yonhap news agency reported.
"From three pm (06:00 GMT) today, there have been some unusual movements under way at Punggyeri where we had thought the first nuclear test would be carried out," Kim was quoted as saying. "We have been closely following developments there to find out whether North Korea is moving to conduct a series of tests as India and Pakistan did," he said.
An unidentified lawmaker who serves on parliament's intelligence committee quoted Kim as telling the committee that there is a "sufficient possibility" of the North carrying out further nuclear tests.
There was no consensus on the size of the North Korean blast. A US official said it could take several days for intelligence analysts to determine whether the event was the result of an unsuccessful nuclear test, a small nuclear device or a non-nuclear explosion.
"In terms of yield, we have it registering at less than four on the Richter scale. That's the kind of thing that could be the result of several hundred tonnes of TNT, rather than a nuclear test," the official added.
Gary Gibson of Australia's Seismology Research Centre put it at about one kiloton, the equivalent of 1,000 tonnes of TNT. Russia's RIA news agency quoted Russian Defence Minister Sergei Ivanov as saying it ranged between 5 and 15 kilotons. The US Air Force dropped a 12.5-kiloton bomb on the Japanese city of Hiroshima in 1945.
The UN Security Council urged North Korea last week not to carry out a test, warning of unspecified consequences if it did. Speaking after Seoul talks with Japan's Abe, South Korean President Roh Moo-hyun said the North's test was a dangerous ploy that could prompt other countries to develop nuclear weapons.
The United Nation's nuclear watchdog, the International Atomic Energy Agency (IAEA), said Pyongyang's test threatened a global treaty to prevent the proliferation of nuclear weapons.
"This reported nuclear test threatens the nuclear non-proliferation regime and creates serious security challenges not only for the East Asian region but also for the international community," the IAEA said in a statement.
In Tokyo, reporters asked Chief Cabinet Secretary Yasuhisa Shiozaki if Japan, a traditional target for North Korean hostility, might now change policy and acquire atomic arms. He replied: "There is absolutely no change to Japan's policy over nuclear weapons."
Shiozaki said there was no need for those living in Japan to worry about radioactive fallout. "It would be minimal and the effect on humans and the environment would not be a problem," he said.
A US official, speaking on condition of anonymity, said the North had given China a 20-minute warning of its test and Beijing had immediately alerted Washington, Tokyo and Seoul.