Scotland has voted against independence from the United Kingdom in an historic referendum.

Almost 85% of the electorate turned out to vote, an unprecedented proportion in recent decades.

The overall result was reached by simply adding together all ballots but data from the 32 Scottish council areas reveal differences in voting patterns.

How close was the result?

The overall result was slightly wider than predicted with 55% No to 45% Yes but the split varied across areas.

The closest result was Inverclyde with 50.1 No to 49.9% Yes.

The most emphatic No vote was Orkney where 67.2% voted against independence, followed by Scottish Borders and Dumfries & Galloway.

Dundee was the most pro-Yes with 57.4%, followed by West Dunbartonshire and Glasgow, which has an electorate of half a million people.

John Curtice, professor of politics at Strathclyde University, said the result was not as close as opinion polls had been predicting.

"That is not uncommon in these referendums where people are being asked to make a big change. They often draw back at the last minute," he said.

Turnout

An extraordinarily large turnout of 84.6% is the highest seen in recent decades. The last UK general election to come close was in 1951 with 83.9%.

To beat it means looking back to 1910 when women did not have the vote and many men were also disenfranchised.

Glasgow had the lowest turnout at 75%, followed by Dundee on 78.8%.

The highest was East Dunbartonshire at 91% with East Renfrewshire and Stirling also nudging over 90%.

Was the split on party lines?

The European election in May 2014 gives some indication of party political support across Scotland although the turnout was much lower than that for the referendum.

In May, the SNP had the largest vote share overall with Labour second.

In the referendum, three of the four areas to vote Yes had backed Labour in the European election.

Dundee was the exception, backing the SNP in May and voting Yes in the referendum.

Professor of politics at Edinburgh University, Charlie Jeffrey, said party loyalties did not seem to have mattered in the referendum vote.

He said: "We have seen results in Labour strongholds like Glasgow and North Lanarkshire where there has been a 'Yes' vote, and in SNP strongholds like Angus and Perthshire there has been a 'No' vote.

"What we have found is a very strong correlation between the Yes vote and a higher level of unemployment.

"But also a slightly less strong relationship between the more British you feel, the less likely you are to vote 'Yes'.

"These seem to be more significant influences than political party in the outcome."

The latest annual unemployment figures show North Ayrshire the worst affected with a rate of 13.5% of the adult population. This area returned a narrow No vote of 51%.

Neighbouring East Ayrshire has the second-highest unemployment rate with 11.4% and Dundee - which voted Yes - is third with 11.3%.

At the other end of the scale, Shetland, which voted strongly No, has the lowest unemployment with 3.2%, followed by Aberdeenshire on 3.3%.

Youth vote

Some 109,533 youngsters aged 16 to 17 registered to vote after being given the chance to do so for the first time.

A snap poll by Lord Ashcroft asking voters how they had cast their ballots found this age group had voted overwhelmingly for independence, with 71% for Yes.

However among the wider 16-24-year-old age group the Yes vote was 51%, according to the poll.

Glasgow is the area with the biggest total population in Scotland and also has a high number of teen voters. Figures from the 2011 Census show the city had more than 18,000 people aged 13-15.

Depending on when their birthday falls, these youngsters will now be aged 16-19.

Ageing population

At the other end of the demographic spectrum is Scotland's rising older population. The proportion of people aged 65-plus now stands at 16.8%, slightly more than the proportion of under 16-year-olds.

Unsurprisingly, the issue of pensions consistently registered as one of the key issues in the independence debate.

Those areas with a relatively older population are the places where "No" did well.

The Lord Ashcroft overnight poll of 2,047 voters found that 73% over 65s chose No.