A "deeply saddened" President Barack Obama on Saturday hailed late US space pioneer Neil Armstrong as one of the nation's greatest ever heroes, for having inspired a generation to reach for the stars.

Armstrong, the first person to set foot on the moon, died after suffering complications from cardiovascular surgery, his family said earlier. He was 82.

"When he and his fellow crew members lifted off aboard Apollo 11 in 1969, they carried with them the aspirations of an entire nation," Obama said in a statement.

"They set out to show the world that the American spirit can see beyond what seems unimaginable - that with enough drive and ingenuity, anything is possible. And when Neil stepped foot on the surface of the moon for the first time, he delivered a moment of human achievement that will never be forgotten."

Armstrong and fellow Apollo 11 astronaut Edwin "Buzz" Aldrin landed on the moon on July 20, 1969, with an estimated 500 million television viewers looking on in astonishment worldwide.

Armstrong's first words upon stepping on the lunar surface have since been etched in history: "That's one small step for (a) man, one giant leap for mankind."

Obama, who was just under eight years old at the time of the historic Apollo 11 mission, said: "Neil was among the greatest of American heroes - not just of his time, but of all time.

"Today, Neil's spirit of discovery lives on in all the men and women who have devoted their lives to exploring the unknown - including those who are ensuring that we reach higher and go further in space.

"That legacy will endure - sparked by a man who taught us the enormous power of one small step."

Obama's Republican challenger for the White House, Mitt Romney, said Armstrong now "takes his place in the hall of heroes."

"With courage unmeasured and unbounded love for his country, he walked where man had never walked before," Romney said. "The moon will miss its first son of Earth."

The former Massachusetts governor, who spoke with Armstrong just a few weeks ago, said the astronaut's patriotism and passion for space, science and discovery "will inspire me through my lifetime."

Republican House Speaker John Boehner paid tribute to one of Ohio's "proudest sons."

"A true hero has returned to the heavens to which he once flew," Boehner said. "Neil Armstrong blazed trails not just for America, but for all of mankind. He inspired generations of boys and girls worldwide not just through his monumental feat, but with the humility and grace with which he carried himself to the end. Ohio has lost one of her proudest sons. Humanity has gained a legend."

And Pentagon chief Leon Panetta bid farewell on behalf of the US military to one of its own.

"As a decorated Korean War veteran, as an astronaut for NASA, and as the first man to walk on the moon, Neil inspired generations of Americans to believe that as a nation we are capable of achieving greatness that only comes with determination, perseverance and hard work," the US defense secretary said.

"As a true pioneer, his one small step showed all mankind the great feats we can accomplish when we set ourselves to the task."

[Photo via Flickr user BooWow, Creative Commons licensed.]