Normally it is a terrible idea to steal eggs from the nests of wild birds. That is doubly true if the species is endangered, in which case every individual counts. In the UK, anyone caught with a wild bird's egg can be sent to prison for six months.

But in the chilly coastal tundra of Chukotka, in the remote north-east of Russia, conservationists are doing exactly that. Beginning in 2012, Russian and British ornithologists have been taking the eggs from the nests of spoon-billed sandpipers. These little wading birds are critically endangered.

This is no sport, however, and it is entirely legal. The conservationists are raising the stolen chicks themselves, because that way the young birds have a far better chance of survival. Once they are large enough to survive on their own, they are released into the wild.

It is a desperate, last-ditch approach to conservation. But those involved are doing it because the spoon-billed sandpiper's situation is equally desperate.

There are only about 200 breeding pairs of spoon-billed sandpipers left in the wild. The population has declined rapidly over the last few decades.

This is a migratory journey of some 4,970 miles, undertaken by a bird no larger than a sparrow

The source of this crisis does not lie in their breeding habitats in Russia, but far to the south.

Once a young spoon-billed sandpiper has reached the right size, it embarks on an epic migration. It will head south to the Chinese and South Korean shores of the Yellow Sea, and then on to South East Asia.

This is a migratory journey of some 4,970 miles (8,000km), undertaken by a bird no larger than a sparrow. And it is on this journey that the sandpipers face their greatest challenges.

The birds' habitats in the Yellow Sea have been almost swept away.

Away from the Russian tundra, spoon-billed sandpipers are shorebirds. They feed on intertidal mudflats, which are home to millions of small invertebrates.

Most of their eggs and chicks fall victim to predators

But in China and South Korea, these once vast muddy beaches have been converted to dry land for agriculture and industry. That means there are fewer places for the birds to refuel on their gruelling migration.

The habitat loss in the Yellow Sea is a crisis for many migratory shorebirds. These birds all travel along the East Asian Australasian Flyway, which stretches halfway around the world and is one of the great bird migratory routes. Bar-tailed godwits and eastern curlews are also in population free-fall.

Shorebird hunting is also a problem, particularly in South East Asia and south China. Spoon-billed sandpipers are too small to be worthwhile targets for hunters, but they are caught as bycatch in the mist nets set for larger species.

To offset these losses, the sandpipers need to produce lots of young. But that is also something they struggle with.

Spoon-billed sandpiper parents have the odds stacked against them.

Most of their eggs and chicks fall victim to predators, in the form of larger birds, like skuas and gulls, and mammals like foxes and ground squirrels. On average, a breeding pair will produce three or four eggs each year, but they will only add one youngster every two years to the population flying south.

This is where the conservationists come in.

They steal eggs and keep them in incubators. Then they care for the newly-hatched chicks, until the young birds are large enough to fend for themselves.

The process is known as "head-starting". The idea is to harvest eggs as soon as they are laid, then raise the hatchlings in the safety of a temporary aviary.

In theory, head-starting means about seven times more youngsters get the opportunity to start the migration to the Yellow Sea.

The proposal to try head-starting came from the Wildfowl and Wetland Trust (WWT), a British charity. The WWT already hosts the world's only captive population of spoon-billed sandpipers, at its centre at Slimbridge.

Chukotka is three times the area of the United Kingdom and has almost no roads

This group of 23 birds has been established as an "ark" population. The hope is to breed them in captivity, so that if the worst happens in the wild the species will still live on.

In June 2016, two of these captive pairs produced eggs for the first time. Two of the eggs are known to be fertile. The WWT expects them to hatch on Wednesday 29 June and Saturday 2 July.

Still, for now the most intense activity is focused on head-starting.

The head-starting project is located near the fishing village of Meinypil'gyno. In recent years, about a dozen spoon-billed sandpiper pairs have come to a nearby area of tundra to breed.

This place is by far the best-known breeding area for the species in Chukotka. It is also profoundly remote. Chukotka is three times the area of the United Kingdom and has almost no roads. Transport is by helicopter, caterpillar-tracked vehicles and quad bikes.

Each year, the team takes all the eggs from eight nests. If the eggs are stolen early enough in the season, the robbed parents will mate again and lay a new clutch. The team leaves those to their fate.

Taking eggs from such endangered birds was always going to be risky, says Evgeny Syroechkovskiy, head of spoon-billed sandpiper conservation for Birds Russia.

However, there were two aspects of the birds' biology that suggested it might work.

The first encouraging fact was that spoon-billed sandpiper chicks can feed themselves as soon as they have hatched and dried out. Within an hour, they start walking on their oversized legs in search of invertebrates to eat.

The young birds also know instinctively when to begin migrating and where to go. Somehow it is hard-wired in them – unlike young geese and cranes, which need parental guidance.

However, the team still had the problem of what to feed the young birds while they were in the aviary.

"We bring out a dried formulated food with vitamins and minerals for them," says Roland Digby of the WWT, who has been to Chukotka every year since 2012.

But they also try to give the young birds their natural diet: insects. Fortunately, during the Arctic summer the insect population explodes.

The tundra "is moving with mosquitoes," says Digby. "I've been up there and the clouds of mosquitoes have been so thick, you couldn't see 10 metres. It's tough for the aviculturists, but as a fresh live food it is fantastic for the birds, and they thrive on it."

We used the vacuum cleaner to suck mosquitoes into a bag

But during the first year of head-starting, the team faced a crisis. Their young charges would not eat the dried food, and strong winds meant there were no mosquitoes in the immediate area.

They had to go mosquito-hunting in remote valleys, away from the winds.

"There was a whole expedition organised with a quad bike, a vacuum cleaner and a portable generator," says Syroechkovskiy. "We used the vacuum cleaner to suck mosquitoes into a bag, which we then brought back to feed the chicks."

It was a bizarre thing to do, but it worked. "That way we saved our first spoon-billed sandpiper chicks," says Syroechkovskiy.

Now, the project team collects mosquitoes from these dense swarms around the clock. There is no night in the far north at this time of year, and the chicks need lots of food to be ready for their first migration.

"These chicks hatch out and they weigh only 5 grams," Digby says. "They look like little bumblebees with huge feet. By the time they are 20 days old, they are fully fledged and we then release them. At 23 to 25 days old, these birds start that incredible migration."

Each year, the project raises and releases about 30 new birds. Almost of them begin the flight towards the Yellow Sea.

"The first two years of head-starting was a really nervous time for us," says Syroechkovskiy. "It was a lot of effort and investment. And we asked ourselves, was it going to work?"

In 2014, the first head-started birds reappeared at Meinypil'gyno. They had survived the round trip.

Then in 2015, several returnees paired up with wild birds to breed. It is too early to say if the 2016 returnees will also breed successfully, but there is no particular reason to think that they will not.

There is also evidence of a wider gain, says Syroechkovskiy. "In the summer of 2015 we recorded a slight increase in our local population of spoon-billed sandpipers for the first time, after a very steep decline in the previous six years. When you look in detail at the data, you can see the increase is happening because of head-starting."

"Increasingly we are proving that head-starting works," says Syroechkovskiy. "It's quite a special moment when you see all your efforts delivering a result."

However, the team is clear that head-starting alone is not going to save the spoon-billed sandpiper from extinction. In fact, the species is doomed in the wild unless the urgent issues of habitat destruction and hunting can be solved.

Success in saving the spoon-billed sandpiper depends on international cooperation on the Flyway

"Head-starting is giving us a little more time for rather intensive activities for conservation of the species in the non-breeding grounds," says Syroechkovskiy.  "Work on preventing hunting in Myanmar, and trying to prevent habitat loss in China, in particular, is equally very important to what we are doing on the Russian breeding grounds."

Ultimately, the only way to save this tiny bird is to preserve the East Asian Australasian Flyway. Every step of it is essential.

"Success in saving the spoon-billed sandpiper depends on international cooperation on the Flyway," says Syroechkovskiy.

Andrew Luck-Baker is a producer in the BBC Radio Science Unit.

Life on the East Asian Flyway is a four-part series on the BBC World Service.

Join over five million BBC Earth fans by liking us on Facebook, or follow us on Twitter and Instagram.

If you liked this story, sign up for the weekly bbc.com features newsletter called "If You Only Read 6 Things This Week". A handpicked selection of stories from BBC Future, Earth, Culture, Capital, Travel and Autos, delivered to your inbox every Friday.