North Korea has executed Kim Jong-un's uncle as a "traitor for all ages" who sought to grab power, state media announced early on Friday morning.

Jang Song-thaek, previously one of the country's most powerful men, was ousted last week in a spectacular purge. He was stripped of all posts and expelled from the Workers party for offences including factionalism, corruption and dissolute behaviour.

But many had thought his marriage to Kim's aunt – the sister of late leader Kim Jong-il – might save his life until Friday's announcement, which also holds him responsible for other failures in the North, including a disastrous attempt at currency reform in 2010.

State news agency KCNA said a special military tribunal had found him guilty of treason and the Rodong Sinmun newspaper carried a photograph of him handcuffed and held by uniformed guards in the courtroom.

"From long ago, Jang had a dirty political ambition. He dared not raise his head when Kim Il-sung and Kim Jong-il were alive," KCNA said, referring to Kim's grandfather and father.

"He began revealing his true colours, thinking that it was just the time for him to realise his wild ambition in the period of historic turn when the generation of the revolution was replaced."

That was when Jang – who had been purged twice before – moved to the forefront of North Korean politics again. It was assumed that Kim Jong-il wanted to ensure a smooth path to power for his son and successor Kim Jong-un. Jang was seen as a mentor figure or even regent for the young leader.

KCNA added: "The accused Jang brought together undesirable forces and formed a faction as the boss of a modern day factional group for a long time and thus committed such hideous crimes as attempting to overthrow the state."

Adam Cathcart, an expert on North Korea, said accusations of factionalism and seeking power were "pro forma" in such cases, particularly when the penalty was so harsh.

But he noted how specific the charges were and added: "There certainly were discussions about the direction North Korea would take [when Kim Jong-il died]. It would be natural for Jang to want to be part of a collective leadership system.

"But North Korea is not moving towards a collective system: it's all about the one leader, whether he is 30 or 69 years old. If he was 18 he would still be a genius. It's the divine right of Kims."

Kim has made sweeping changes to the hierarchy in North Korea, changing key military personnel repeatedly as well as removing civilian members. But Jang's execution is unprecedented because family members are normally dealt with more leniently and quietly.

It is unclear whether the position of his wife Kim Kyong Hui – who was also seen as something of a mentor for Kim following her brother's death – has been affected.

Two of his aides are believed to have been executed already and many analysts believe that more will follow.

"The drama of this and the speed of this and the sense of a bit of improvisation going on – that's somewhat alarming," said Cathcart.

But he added: "Kim has been very lucky in the external environment and I think he will continue to be. For all the bile directed from South Korea, Japan and the US and even China, none of those countries are interested in grabbing this hornet's nest and shaking it right now."

The KCNA report accuses Jang of letting people who had been previously dismissed return to work for the party as he sought to form a faction.

It attacked Jang as "worse than a dog" and accused him of working in earnest to claim power after Kim Jong-il's death two years ago.

He was also criticised for trying to project himself "as a special being on a par" with the leader and for only "half-heartedly clapping" when Kim Jong-un became vice-chairman of the Central Military Commission before his father's death.

In the US, Patrick Ventrell, a spokesman for the National Security Council, said: "If confirmed, this is another example of the extreme brutality of the regime."