Image copyright Getty Images Image caption Young people may enjoy visiting the seaside but do they want to live there?

Four in 10 coastal communities in England could see a decline in the number of residents aged under 30 by the year 2039.

Analysis by BBC News of population projections has found seaside towns in northern England could see the biggest decline in under-30s.

The Parliamentary Group for Coastal Communities said funding cuts meant seaside towns were "being left behind".

The government said it had invested more than £200m in coastal communities.

The coastline in England is home to some of the most beautiful but also poorest places in England.

Some young adults living in the North Yorkshire town of Scarborough said they struggled to envisage a future for themselves living by the sea.

Image caption Kayleigh Wilkinson said lots of friends had moved away from Scarborough because of a lack of jobs

"There aren't many career options in Scarborough," said 24-year-old Kayleigh Wilkinson.

"You either work in a care home like I do, or you work in a shop.

"That's one of the many reasons why people my age are already leaving to work in bigger cities like York and Leeds."

The Office for National Statistics (ONS) produces population projections based on previous and current demographic trends, including how many people have moved away from areas in previous years as well as birth and death rates.

According to these figures, Scarborough could see a 7% fall in the number of people under 30 living in the area by 2039, meaning a potential fall of some 2,000 children and young adults over the next two decades.

Media playback is unsupported on your device Media caption What's it like to be young and live in a coastal town?

Ryan Broadbent, 21, moved from Scarborough to Leeds to study at university and said he could not see himself returning to the town.

"If you spend £30,000 on going to university the last thing you want to do is move back to a place where you can only find a low skilled job," he said.

"It's not just jobs, there's very little to do at the weekend for young people. We were promised a multi-screen cinema in Scarborough but that hasn't happened."

Image copyright Getty Images Image caption Coastal towns like Scarborough once attracted hundreds of thousands of visitors every summer

Twenty-year-old Reece Wilde was more optimistic about the future of the town, having just opened a cafe in the centre of Scarborough.

"I love this place and I think there are positive things happening," he said.

"There are people like me setting up independent bars and coffee shops.

"But what Scarborough and other seaside places need to do is think of what they can offer people all year round, instead of just in the summer."

What could happen to England's coastline population?

Image copyright Getty Images Image caption Eight million people currently live in local authority areas in England with a coastline

BBC News has analysed the population projections made by the ONS for 75 local authorities in England with a coastline.

Thirty of them could see a fall in the number of residents under the age of 30 by the year 2039.

The biggest decline in the number of under-30s could be in the north of England, with Copeland and Barrow-in-Furness in Cumbria and Northumberland all seeing a fall of more than 10% in the number of young people and children.

In contrast, coastal authorities in the south, such as Bristol (+15%), Southampton (+7%) and Canterbury (+6%) could see substantial rises in the number of children and young people.

Under 30s population decline on the coast Projected percentage (%) change between 2019 and 2039

A report published earlier this year by the House of Lords said coastal communities "had been neglected for far too long".

It said most seaside towns still relied on tourism but many in the future would need to diversify their economies.

Mike Hill, the Labour MP for Hartlepool and chair of the All Party Parliamentary Group on Coastal Communities, said coastal communities had not received enough investment from the government.

This meant they could not create new jobs that would keep young people living by the sea in the decades to come.

"In my town we've created high-skilled well-paid jobs in sectors such as wind energy and carbon capture technology," he said.

"But there is no getting away from it, these population projection figures are frightening, and without action could signal the death of some coastal towns.

"Government austerity and the underfunding of seaside towns is at the heart of the reason why these communities feel like they've been left behind."

Image copyright Getty Images Image caption Hartlepool in the North East is one of the most deprived places in England

Responding last month to the House of Lords findings, the Ministry of Housing, Communities and Local Government said it acknowledged coastal communities were "comparatively more deprived".

But it said regenerating coastal towns was a complex issue and that by the next year the government would have invested more than £220m in projects based in coastal communities that were already having tangible results.

Corrections 24 July 2019: An earlier version of this story incorrectly calculated figures for the changes in under-30s population in some local authority areas. These figures have now been updated.