RIO DE JANEIRO, Aug. 20 (Xinhua) -- Usain Bolt declared himself "the greatest" after signing off on his Olympic career with a ninth gold medal here on Friday.

The 29-year-old ran an electrifying final leg to anchor Jamaica's second straight Olympic men's 4x100m relay victory.

The result gave Bolt his ninth Olympic gold medal and secured an unprecedented three consecutive titles in the 100m, 200m and 4x100m relay.

"There you go, I am the greatest," said Bolt, who this week said the Rio Olympics would be his last. "I am just relieved. It's happened. I am just happy, proud of myself. It's come true. The pressure is real. I look at it as an accomplishment."

When asked how he planned to celebrate, Bold replied: "I'll stay up late tonight."

Also represented by Asafa Powell, Yohan Blake and Nickel Ashmeade, Jamaica clocked 37.27 seconds to beat Japan by 0.33 seconds, with Canada taking bronze in 37.64.

The United States originally finished third but were disqualified for an illegal baton change. Trinidad and Tobago were also disqualified, promoting China to fourth.

Bolt began the final leg of the race slightly trailing Japan's Aska Cambridge but quickly caught his rival before surging clear in the last 50m with his trademark burst.

He claimed the 100m gold here by defeating long-time rival Justin Gatlin on Sunday. And on Thursday he clinched the 200m title by finishing ahead of Canada's Andre de Grasse.