Bred by an emperor and nearly killed off by communists, the Hungarian mangalica pig has been through a lot during its nearly two centuries of existence. A lumbering, chunky beast with a sheep-like coat, it is the hairiest and fattiest of pigs. And according to its many fans, the mangalica is also one of the tastiest.

From being on the verge of extinction three decades ago, the mangalica has made a remarkable comeback to the farms, tables and hearts of Hungarians over the past decade, and has recently been taking the global fine-dining scene by storm from the US to Japan, where its fatty, marbled texture has led it to be nicknamed “Kobe pork”. In Hungary, the breed has been officially registered as one of the country’s national treasures.

However, the pride of Hungarian agriculture is now facing another threat: the epidemic of African swine fever sweeping through eastern Europe, which has led to a number of culls.

The growing popularity of mangalica is also causing disputes with Hungary’s neighbours. There was a furious reaction earlier this month when a popular US gastro-blogger introduced mangalica as a “medieval Romanian food” in a video that garnered nearly a million views on YouTube.

Simmering tension remains over Hungary’s historical role as ruler of part of the country’s territory, and the Hungarian press was outraged. “It was not enough that they took away Transylvania, trying to expropriate our culture and our historical memories … Now they also want to steal mangalica from us,” wrote the rightwing news portal 888.hu.

“It can become like hummus is for Lebanon and Israel,” said Péter Tóth, the president of Hungary’s Mangalica Breeders Association, in an interview at an upmarket Budapest restaurant over a plate of mangalica ham cuts.

While noting that all mangalica currently in Romania are recent imports from Hungary, the pig’s history is international, Tóth said. The breed was created in the 1830s after the Habsburg emperor in Vienna was gifted 11 fatty, long-haired pigs by the prince of Serbia and had them cross-bred with some old Hungarian breeds near Arad, now part of Romania.

At one point, 90% of all pigs in Hungary were mangalica, with the high fat content prized because the copious lard could be stored for much longer than meat. With the onset of electricity and refrigeration, production declined and it became more of a luxury product. After the second world war, the communist system almost destroyed the mangalica; only about 300 sows were maintained in reservations for scientific purposes. The meat was nowhere to be found.

The long-haired breed was created in the 1830s. Photograph: Oleg Upalyuk/Alamy

As a young veterinary student in Spain in the early 1990s, Tóth told a Spanish friend about the fatty Hungarian pigs and the pair launched a project to save the mangalica. “I put adverts in local newspapers: ‘If you’ve seen a mangalica, please let me know,’” he recalled. He bought up the whole population and for several years bred them with Spanish investment, until they were ready to send fatty pork for curing in Spain by the late 90s.

There are now more than 200 mangalica farmers in Hungary and the meat is on sale in almost every marketplace, at prices about four times higher than normal pork.

Zsóka Fekete, who runs a mangalica farm in eastern Hungary, said: “It’s different from any other meat. The texture is marbled, especially in the neck. It’s a completely unique taste.”

She worked in a multinational company in Budapest before deciding in 2012 to return to her family farm and buy 20 mangalica sows, which she has since grown to 300. She has a loyal client base including Michelin-starred restaurants and Budapest mangalica lovers, who form queues to buy her produce when she makes the trip to the capital once a fortnight.

Indeed, the only blip on the horizon for the mangalica is the African swine fever epidemic. The first cases were detected in Hungary’s wild boar population last April, and while no domesticated pigs have yet caught the virus, due to its extreme contagiousness, any time a diseased boar carcass is found, all pigs within a two-mile (3km) radius must be culled.

It is particularly dangerous for the mangalica, which live in semi-open conditions, and new security measures have been put in place, including double fencing and a ban on visitors to farms. So far, about 1,200 mangalica have been slaughtered across Hungary, more than 10% of the population.

Tóth said the government had recently approved a special strategy to save the mangalica should the situation become critical: an emergency gene-banking system will be set up, and the most valuable mangalica specimens will be moved to safe spaces such as zoos or universities.

As for climate concerns around meat consumption, it is likely to be a while before that affects sales in Hungary, where pork is ubiquitous and vegetarianism still seen as quirky eccentricity. But Tóth, surprisingly, advocates for his compatriots to eat less meat.

“I am against the low quality and the animal suffering involved in industrially farmed meat,” he said, skewering a fatty slice of mangalica jamon with a fork. “Humans should eat less meat, for sure. But when they do, it should be high quality. For example, one piece of mangalica per week.”