The court in Nanterre, outside Paris, said Amazon France had “failed to recognise its obligations regarding the security and health of its workers”.
While carrying out the health evaluation, Amazon can prepare and deliver only “food, hygiene and medical products,” the court said.
The injunction must be carried out within 24 hours, or Amazon France could face fines of €1 million per day.
The American e-commerce giant has been hiring thousands of workers as business booms in countries affected by the coronavirus outbreak after authorities imposed business closures and stay-at-home orders to try to limit infections.
But Amazon France's biggest labour union took the company to court saying more than 100 workers were being forced to work in close proximity despite the nationwide ban on public gatherings in force since mid-March.
Last month, French Finance Minister Bruno Le Maire accused Amazon of putting “unacceptable” pressure on employees after unions claimed the retailer was refusing to pay staff who did not go in to work for fear of coronavirus contagion.
His comments came after hundreds of employees walked out at several Amazon processing centres in France, exercising the “right of refusal” in France's labour code if an employee considers there is a risk to health or safety.
Amazon disputed claims that it was not taking sufficient precautionary measures, saying it had imposed stricter cleaning protocols and taken steps “so that employees can keep the necessary distance from one another.”