Medicine is being stockpiled in the United Kingdom in preparation for a messy Brexit.

French drugmaker Sanofi and its Swiss rival Novartis confirmed Wednesday that they're stockpiling treatments to prepare for a scenario where Britain crashes out of the European Union without a Brexit deal.

Hugo Fry, managing director for the United Kingdom at Sanofi, said the company had secured additional warehouse capacity to increase its stock of medicine in Britain to 14 weeks from the usual 10.

"Sanofi is confident that its contingency plans will ensure that people in the United Kingdom can access the treatments they need," Fry said in a statement.

The action by Sanofi was first reported by The Wall Street Journal. Novartis (NVS) said in a statement that it was planning to "hold increased inventories" in Britain.

The slow pace of Brexit negotiations has heightened fears in recent weeks that Britain may leave the European Union in March 2019 without a transition deal to keep it temporarily in the bloc's single market and customs union.

Crashing out of the bloc would mean additional red tape and border checks for businesses including drugmakers.

According to Germany's Merck, 35 million packages containing medicines are shipped from the European Union to the United Kingdom each month. Some 45 million packages travel in the opposite direction.

Merck (MKGAF) declined to comment on specifics, but said it was planning for a variety of scenarios. Pfizer (PFE) said that it has "carried out detailed assessments of the supply of all our medicines with the focus on ensuring we will continue to have them available."

UK Health Secretary Matt Hancock told the UK parliament last week that the government is working to ensure the "health sector and industry are prepared in the event of a no deal [scenario]."

"We're working with industry to prepare for a potential need for stockpiling — this is exactly the type of contingency planning that you would expect us to be doing," he said.

Related: Messy Brexit could lead to food shortages and grounded flights

Sanofi (GCVRZ) said that without a transition deal, the European medicines regulator will consider the United Kingdom a third country and place extra controls on any imported medicines.

To prepare for that, it's shifting some jobs in testing, quality control and labeling from the United Kingdom to other European Union countries.

UK pharmaceutical company GlaxoSmithKline (GLAXF) also said it would boost its operations in the rest of the European Union ahead of Brexit.

The British government has been accused in recent days of not doing enough to prepare for a messy Brexit.

One battle is over potential food shortages, and whether the government or businesses should be stockpiling supplies. The Food and Drink Federation said this week that the industry does not have the capacity to stockpile supplies.