Cupar is a community, previous royal burgh and also parish in Fife, Scotland. It lies in between Dundee and Glenrothes. According to a 2011 population price quote, Cupar had a population around 9,000, making it the nine largest negotiation in Fife, and also the civil church a population of 11,183 (in 2011). It is the historic county town of Fife, although the council now rests at Glenrothes. The community is believed to have actually expanded around the site of Cupar Castle, which was the seat of the sheriff and also was possessed by the earls of Fife. The area became a centre for judiciary as the county of Fife and also as a market town catering for both cattle and sheep. In the direction of the last stages of the 13th century, the burgh became the site of a setting up of the 3 estates - clergy, the aristocracy and also burgesses - organised by Alexander III in 1276 as a precursor of the Parliament of Scotland. Although written info of a charter for the contemporary town was lost, proof suggested that this existed as one of the many homes possessed by the Earls of Fife by 1294. Throughout the center of the 14th century, the burgh started to pay custom-mades on taxable incomes, which possibly meant that royal burgh condition was given sometime between 1294 and also 1328. The earliest file, describing the royal burgh, was a grant by Robert II in 1381 to offer a port at Guardbridge on the River Eden to help enhance trade with Flanders. This grant was officially recognised by James II in 1428.