The figures soared after the re-launch of the National Museum of Scotland in Edinburgh and the opening of the Riverside Museum in Glasgow, both of which have given the country's tourism industry a massive boost.
The National Museum was 2011's busiest attraction with almost 1.5 million visits – a rise of 141% on 2010 following its extensive refurbishment. The Riverside Museum notched up more than one million visitors since it opened in June 2011.
The findings were compiled by researchers at Glasgow Caledonian University's Moffat Centre, and were taken from 649 tourist sites across Scotland.
Malcolm Roughead, chief executive of VisitScotland, said: "These are extremely encouraging figures, helped in no small part by the continuing trend for Scots holidaying at home and the 'daycation' market, which last year contributed £6.2 billion to the Scottish economy. Scotland's world-class attractions are key to the visitor experience."
Professor John Lennon, director of the Moffat Centre, added: "Partly as a result of the new and upgraded attractions, the Scottish tourism industry continues to develop, and we see positive trends."
The research shows that free admission attractions were the biggest winners, with twice as many visitors overall as paid-for sites.
Historic Scotland's Edinburgh Castle was once again the most popular paid-for attraction, attracting 1.3 million visitors – a rise of 7.6% on the previous year. It has topped the list since 1991 when the figures were first collected.
Stirling Castle enjoyed a rise of 14.9% to 433,393 visitors following the re-opening of the Royal Palace apartments, which underwent a £12 million refurbishment to restore them to how they might have looked when Mary, Queen of Scots lived there. The new facilities also include a display on the original Stirling Heads, a collection of oak medallions from the 16th century.
Stephen Duncan, Historic Scotland's director of commercial and visitor attractions, said: "We are delighted that Edinburgh and Stirling castles have had another good year.
"The investment in the Royal Palace apartments and upgrading of visitor facilities at Stirling have proved very popular, a testament to the incredible research and skill that went into creating an authentic experience."
The Robert Burns Birthplace Museum in Alloway, managed by the National Trust for Scotland (NTS), also experienced a large increase in visitors with a rise of 49.1% to 444,947.
The site, on the outskirts of Ayr, was relaunched in 2010 and holds the world's largest collection of artefacts relating to the bard. Its success contributed towards Ayrshire and Arran enjoying the greatest increase in visitor numbers in the whole of Scotland with a rise of 29.6%.
Mr Lennon said: "Ayrshire and Arran have performed well as a region, largely due to NTS's Robert Burns Birthplace Museum and Dean Castle Country Park in Kilmarnock. Both attractions performed exceptionally well.
"Often, as in this case, the increase is due to one or two attractions doing particularly well, which positively impacts on the rest of the area. And with the Robert Burns Birthplace Museum, visitors will also have visited other local attractions at the same time."
Mr Lennon added that various factors in previous years may have contributed to lower overall visitor numbers.
He said: "In previous years we've had shocks such as the volcanic ash cloud and security issues which have negatively impacted on the figures. No doubt the recession and fuel costs have also taken their toll, particularly on the smaller and more remote attractions without a secure source of funding."