First Minister Nicola Sturgeon has led Scottish tributes to "global legend" Sir Sean Connery.
Former Prime Minister Gordon Brown and two former first ministers also paid their respects to the screen icon, who has died aged 90.
And among those who shared warm memories on social media were Trainspotting star Robert Carlyle and crime writer Ian Rankin.
Ms Sturgeon said: "Our nation today mourns one of her best loved sons."
The first minister admitted she was "heartbroken" when she heard the news.
She added: "Sean was born into a working class Edinburgh family and through talent and sheer hard work, became a film icon and one of the world's most accomplished actors."
Ms Sturgeon said the Oscar winner will be best remembered for his iconic role James Bond and described him as "the classic 007".
She added: "Sean was a global legend but, first and foremost, he was a patriotic and proud Scot.
"His towering presence at the opening of the Scottish Parliament was a sign of his dedication to his country.
"He was a lifelong advocate of an independent Scotland and those of us who share that belief owe him a great debt of gratitude."
The first minister said she was honoured to have known the actor and recalled: "When I last spoke to him it was clear even then that his health was failing - but the voice, the spirit and the passion that we all loved so well were still there.
"I will miss him. Scotland will miss him. The world will miss him."
Former Prime Minister Gordon Brown tweeted: "So sorry to see that Sean Connery has passed away. I enjoyed many conversations with him over the years. A great acting legacy endures."
Former first ministers also paid their respects to the screen icon.
Alex Salmond said: "The world's greatest Scot, the last of the real Hollywood stars, the definitive Bond.
"Sean Connery was all of these things but much more. He was also a staunch patriot, a deep thinker and an outstanding human being."
He added that he had the "rare privilege" of being Sir Sean's friend for more than 30 years.
The ex-SNP leader also praised the actor's charity work for the Scottish International Education Trust and his "unshakable" support for independence.
So sorry to see that Sean Connery has passed away. I enjoyed many conversations with him over the years. A great acting legacy endures. ~ GB— Gordon & Sarah Brown (@OfficeGSBrown) October 31, 2020
Mr Salmond concluded: "He was honest and brave and it has been one the privileges of my life to count him as a friend.
"His sense of irony and humour were legendary as was his love of his country. 'Scotland Forever' wasn't just tattooed on his forearm but was imprinted on his soul."
Labour peer Jack McConnell tweeted: "Sean Connery was an outstanding actor, great company in private and a terrific ambassador for Scotland. Savouring memories and thinking of his lovely family today."
At Holyrood, Scottish Conservative group leader Ruth Davidson tweeted: "I loved watching Bond movies with my dad. He raised me in the true religion that Sean Connery was the 'proper' 007. True film icon."
Scottish Labour leader Richard Leonard said: "Sean Connery will go down in history as one of Scotland's greatest acting talents and as an iconic figure in world cinema and culture. I extend my condolences to his family and friends."
Actor Robert Carlyle tweeted: "RIP Sir Sean Connery.. a trailblazer, a true legend and a gentleman."
He also shared a picture captioned: "One of my proudest moments.. with the great man in 2008."
One of my proudest moments.. with the great man in 2008. pic.twitter.com/4jk51ElueL— Robert Carlyle (@robertcarlyle_) October 31, 2020
Sir Sean Connery also played for Scottish Lowland Football League club Bonnyrigg Rose Athletic, based in Midlothian, in the early 1950s.
On Saturday, the club tweeted a picture of a rainbow over their New Dundas Park ground and paid tribute to "probably our most famous footballer".
The British Academy of Film and Television Arts (Bafta) Scotland tweeted: "We are so sad to hear of the death of Scottish acting legend Sir Sean Connery. A true Scottish icon."
A rainbow falls on to NDP following the sad announcement of probably our most famous footballer & one of the most iconic Scots of all time. We would like to offer our deepest condolences to his family. RIP Sean. https://t.co/pRZEd3qoBq pic.twitter.com/OMQauQiVTa— Bonnyrigg Rose Athletic ( with a 🌹😷) (@BonnyriggRose) October 31, 2020
And crime writer Ian Rankin posted: "Aw hell. Got to know him for a short time several years back. A natural. You couldn't take your eyes off him onscreen. RIP."
The Rebus creator later revealed he duped Sir Sean into signing a DVD cover of a movie the star "hated" by claiming it was for his son.
I was due to meet Sean to discuss a writing project. Had to take sth for him to sign. Grabbed this. He hated the film so much he almost refused till I lied that it was for my young son... pic.twitter.com/yd8uhKdJ5j— Ian Rankin (@Beathhigh) October 31, 2020