North Korean state media has confirmed the country has successfully conducted a nuclear test after weeks of threats.

The detonation caused a tremor with a magnitude of between 4.9 and 5.1, sending shockwaves through the Korean peninsula.

Analysts in Seoul estimate the yield of the blast at between 6 and 7 kilotons, or about the same or slightly larger than the North's last nuclear detonation in 2009.

North Korea says the test used a miniature nuclear device and was conducted in a "safe and perfect manner".

"A third nuclear test has been successfully staged," the state-run Korean Central News Agency (KCNA) said.

"The nuclear test was conducted as part of measures to protect our national security and sovereignty against the reckless hostility of the United States that violated our republic's right for a peaceful satellite launch.

"It was confirmed that the nuclear test that was carried out at a high level in a safe and perfect manner using a miniaturised and lighter nuclear device with greater explosive force than previously did not pose any negative impact on the surrounding ecological environment."

It is the third time North Korea has detonated a nuclear device, after earlier tests in 2006 and 2009.

Experts will want to establish if the rogue state used plutonium or has employed highly enriched uranium for the first time, giving it another source of material for nuclear weapons.

Pyongyang has been threatening a nuclear test for weeks, despite warnings of severe repercussions from the UN Security Council.

South Korean officials said a tremor was detected just before midday local time, and they were almost certain it was not an earthquake.

Scientists in Japan also reported the tremor was "different from a normal earthquake".

South Korea's defence ministry says the North gave both the US and China advanced warning before conducting the test.

A UN diplomat added the North ignored a "strong warning" from China against staging the test.

Sorry, this video has expired Former ambassador discusses N Korea 'nuclear test' ( Scott Bevan )

International nuclear test monitoring agency, the Comprehensive Nuclear-Test Ban Treaty Organisation (CTBTO), said it had detected an "unusual seismic event" in the North.

CTBTO's executive secretary Tibor Toth said the event's location was "roughly congruent with" the 2006 and 2009 tests.

"For now, further data and analysis are necessary to establish what kind of event this is," he said in a statement.

"If confirmed as a nuclear test, this act would constitute a clear threat to international peace and security, and challenges efforts made to strengthen global nuclear disarmament and non-proliferation, in particular by ending nuclear testing."

The US Geological Survey said the epicentre of the tremor, which was only one kilometre deep, was close to North Korea's known nuclear test site.

Emergency meeting

The UN Security Council will hold an emergency meeting on the apparent nuclear test early tomorrow morning (AEDT).

UN chief Ban Ki-moon condemned the nuclear test, with a spokesman labelling it a "clear and grave violation" of Security Council resolutions.

Diplomats have said previously the US, South Korea and European members would want the Security Council to adopt a resolution that would impose new sanctions on Pyongyang in the event of a third nuclear test in defiance of earlier council resolutions.

The announcement that the device was "miniaturised" will set alarm bells ringing, with suggestions that Pyongyang has mastered the technically complex process of producing a warhead small enough to fit on a long-range missile.

North Korea received widespread condemnation after the launch of a long-range rocket in December.

Pyongyang said it was successful in putting a satellite into orbit and insisted the launch was for peaceful purposes.

However many observers noted the rocket launch was more likely to be a ballistic missile test.

Proven miniaturisation ability would take on added significance in the wake of December's rocket launch, which marked a major step forward in the North's ballistic prowess.

'Extremely concerned'

North Korea risks driving a wedge between itself and China with the latest nuclear test, which goes directly against the wishes of its major ally.

China supported the recent UN Security Council measures designed to dissuade Pyongyang from further nuclear tests.

Last week the Chinese government said it was "extremely concerned" as the North prepared for more tests.

North Korea is constantly taunting the United States, and last month threatened further rocket launches and a nuclear test that would target the US.

Last week, North Korea's official website, Uriminzokkiri, posted a video to YouTube which depicted a US city resembling New York engulfed in flames after an apparent missile attack.

North Korea angered the world community by launching a long-range rocket on December 12 last year. ( Reuters/KCNA )

ABC/wires