The court in Paris said on its website on Friday that the 2011 law "conforms to the constitution" and is not "disproportionate".

France banned fracking in 2011 and cancelled exploration licences held by companies including Schuepbach and Total SA, the country's biggest oil company, after protests by environmental groups.

Schuepbach Energy LLC, a Dallas-based explorer, complained to the court that the law was unfair after having two exploration permits revoked because of the ban. President François Hollande has said France won't allow exploration of shale gas energy even as the country seeks to reduce its reliance on nuclear energy and keep down costs for consumers.

"It's a judicial victory but also an environmental and political victory," French environment minister, Philippe Martin, said today after the ruling. "With this decision the ban on hydraulic fracturing is absolute."

The technique, which involves blasting a mixture of water, sand and chemicals underground to release oil and gas from shale rock, has raised the ire of environmental groups who fear groundwater contamination.

Schuepbach argued in court in September that there isn't a study that establishes risks from fracking. The explorer also said the ban was unfair because the drilling technique may still be used in French geothermal energy projects.

The court ruled that in imposing the ban, lawmakers were pursuing a legitimate goal in the general interest of protecting the environment and noted differences between geothermal and shale gas exploration techniques. The court also rejected an argument that the ban went against property rights.

The GEP-AFTP oil and gas lobby said in a statement said in a statement: "France is depriving itself of exploration that could evaluate potentially large nonconventional carbon resources," adding that it deplored the court decision. France should create a commission to experiment with shale drilling in order to evaluate the size of reserves, the lobby said.

France and Poland have the greatest potential for recoverable shale gas in Europe, the International Energy Agency (IEA) has said. In the US, where fracking is widely used, oil output is poised to surpass Saudi Arabia's by 2020, making the country almost self-reliant, according to the IEA.

The ban can no longer be attacked in court and will benefit the fight against carbon emissions from the burning of fossil fuels, Martin said.

"Beyond the question of fracking, shale gas is a carbon emitter," he said. "We must set our priorities on renewable energies."