France has said it will ban the controversial but widespread practices of live-shredding male chicks and castrating piglets without anaesthesia, in a move cautiously welcomed by animal welfare activists.

Some 7 billion male chicks, unwanted because they provide neither meat nor eggs, are culled around the world every year. Many are ground up alive, others are gassed, electrocuted, or asphyxiated in plastic bags.

France will be one of the first countries to ban the mass culling of chicks using any of these methods, starting next year.

“From the end of 2021, nothing will be like it was before,” agriculture minister Didier Guillaume said on Tuesday in Paris as he announced the measure long demanded by campaigners.

Guillaume said he hoped a method would be found soon that would allow farmers to determine the gender of a chicken embryo in the egg before it hatched. Researchers have been working on devising a viable method for years, but to date, the science requires each egg to be pierced to take samples – a technique that is not economically viable on an industrial scale.

Switzerland banned chick shredding in September last year, though it was a rare practice among Swiss poultry farmers.

Germany, where 45 million male chicks are macerated each year, outlawed it too, but a top administrative court ruled in June that the slaughter could continue until a method was found to determine the sex of an embryo in the egg.

France and Germany announced last November they would work together to put an end to the chick massacre. An EU directive from 2009 authorises shredding as long as it causes “immediate” death for chicks less than 72 hours old.

Also from next year, Guillaume announced, France would require anaesthesia be given to piglets being castrated.

Neutering is done to encourage slaughter animals to grow fatter and prevent a potent smell said to emit from the fatty meat of non-neutered boars.

France prides itself on its meat and poultry industries, but there have been growing tensions in recent years between producers and activists calling for radical changes in farming methods.

A series of French butcher shops have been vandalised by activists who say eating meat is an immoral violation of the rights of other species.

The Compassion in World Farming (CIWF) animal lobbying group said the real aim should be to stop the castration of piglets altogether, and expressed disappointment that Guillaume did not announce a ban on eggs from cage-raised chickens.

For its part, the French L214 group which opposes all meat consumption, said the measures were “not ambitious” and “do not address the basic problems”. “There is nothing on slaughter conditions, nor on how to exit from intensive animal farming,” it said.

Guillaume said agriculture ministers meeting in Brussels on Monday decided to put in place a responsible husbandry labelling system on all European animal-based products, starting next year.

An opinion poll in January found that three-quarters of French people did not believe the government was doing enough for animal protection.