He was the flame-haired musical star of 18th century Venice, known to his fans as Il Prete Rosso – the Red Priest. Antonio Vivaldi's reputation, however, spread further than the confines of the Italian city state where he groomed young abandoned girls to become musical prodigies.

Among those who came to worship at the altar of the king of baroque was a keen young flautist named Lord Robert Kerr, son of the 3rd Marquess of Lothian. The young Scot returned to his homeland with one particularly prized souvenir from his Grand Tour: a handwritten manuscript of a flute concerto by the legendary composer.

The long lost piece was discovered at the National Archives of Scotland in Edinburgh, after being forgotten by the classical music world, and yesterday it was played in public for the first time in 250 years.

Il Gran Mogol was among a series of four concertos written by Vivaldi in the latter part of his career, about 1730 – a decade before he moved to Vienna, where his star was to dramatically wane with the death of his patron, the Emperor Charles VI, and where he was to die a virtual pauper.

The piece, between six and seven minutes long, will be played by early music ensemble La Serenissima in Perth, Scotland, next year. It was authenticated by musicologist Andrew Woolley from the University of Southampton, who was investigating an unrelated manuscript when he came across it by chance.

"It is a truly exquisite piece of music from the late baroque period. It has two fast movements either side of a very fine slow movement," he said.

Vivaldi never travelled to India, but it is believed the work was written in honour of a Venetian merchant with connections to the Mogul Empire. It belonged to a quartet of "national" concertos which were in fashion at the time, including La Francia, La Spagna and L'Inghilterro, which remain lost to this day.

The four-part structure echoes that of Vivaldi's most famous work, The Four Seasons, written for violin in 1725, and which has become one of the most easily recognisable pieces of classical music.

The concerto, which was verified by comparing it to a simplified manuscript held in Turin, is almost complete, but is missing a part for the second violin. Mr Woolley was able to reconstruct the lost section by referring to the Italian reworking.

The Scottish version, for which the young aristocrat is believed to have paid about one guinea, was preserved among the family papers of the Marquesses of Lothian. Today its value is estimated at hundreds of thousands of pounds, despite not being written in the hand of Vivaldi.

"This piece was previously known only from a mention in the sale catalogue of an 18th-century Dutch bookseller. Discovering that it is actually in existence is unexpected and hugely exciting," said Mr Woolley.

Evidence of Lord Robert Kerr's interest in music has been tracked down to local journals of the time around his home in the Scottish Borders, which reveal his interest in the flute and the fact he undertook formal instruction in music before receiving his commission in the army. He died at Culloden in 1746 fighting for the Government forces against the Jacobite rebels.

As for Vivaldi, he began to go out of fashion in the decades after his death in 1741 with the advent of German music, so that by the middle of the 19th century his reputation was at rock bottom. It was partially revived in the early part of the 20th century with the discovery of another lost archive in a monastery in Piedmont, where 14 folios believed lost during the Napoleonic Wars were found.

The popularity of his concertos and operas has continued to grow, and his work is now subject to a variety of modern interpretations, most notably from the violinist Nigel Kennedy, whose 1989 version of The Four Seasons sold two million copies and became one of the biggest selling classical records in history.

There have been efforts to recast Vivaldi's posthumous image as a scandalous figure. A still-pending biopic of his life starring Joseph Fiennes and Gérard Depardieu has been described by one newspaper as characterising him as a "sex-obsessed rock star" – but the reality is less licentious.

For the best part of 40 years, he lived with his parents and devoted himself to teaching violin, conducting the choir and orchestra at the Ospedale della Pietà, a musical orphanage for poor and illegitimate children where baby girls were passed through a hatch in the wall.

After being coached by Vivaldi, the most musically accomplished children went on to become performers in their own right. It is possible that Lord Kerr may have sat through mass at the Pietà, which was seen as a cultural highlight of the Grand Tour despite the philosopher Jean-Jacques Rousseau describing himself as "desolate" after meeting the "ugly girls", many of whom were scarred or disfigured through poverty and disease.