However, Internet freedom advocates protesting U.S. surveillance programs were among thousands of demonstrators who gathered in Stockholm for a peaceful protest against Obama's visit.
Swedes reacted with outrage in 2008 over a law that gave a Swedish intelligence service the green light to snoop on email traffic crossing the country's borders. Sweden's small Pirate Party, which advocates freedom on the Internet and is highly critical of government surveillance, has inspired the creation of similar parties across Europe and beyond.
Air Force One touched down in Stockholm Wednesday morning after an overnight flight from Washington. Obama was greeted on the mild, sunny morning by crowds that lined the streets in central Stockholm to watch his motorcade speed by.
Obama's trip marked the first bilateral visit by a sitting U.S. president to the northern European nation. Thousands of armed police were deployed on city streets, many roads and parks were closed in the downtown area, and concrete barriers and steel fences have sprung up in many locations near where the president was staying.
Following his meeting with the prime minister, Obama paid tribute to the late Swedish diplomat Raoul Wallenberg, who is credited with saving at least 20,000 Jews during World War II. Wallenberg was arrested by Soviet forces in 1945 and mysteriously disappeared.
As he spoke of Wallenberg, Obama appeared to make a veiled reference to the choice that confronts him about using military force in retaliation for a deadly chemical weapons attack in Syria, where more than 100,000 people have already died in a civil war. The president spoke of "our power when we choose, not simply to bear witness, but also to act."
Wallenberg's family had planned to present a letter to Obama asking for help in pressing Russia to shed light on Wallenberg's fate.
Obama also ate dinner Wednesday night with other Nordic leaders from Norway, Iceland, Finland and Denmark.
Associated Press writers Josh Lederman, Karl Ritter and Malin Rising in Stockholm and Jack Gillum in Washington contributed to this report.
Follow Julie Pace at http://twitter.com/jpaceDC