Image caption The new cap should make a more secure seal over the leaking wellhead

BP has been given 24 hours to answer questions on the Gulf of Mexico oil spill, the US government's incident commander said.

Adm Thad Allen sent a letter to the oil giant's managing director saying the company must hand over "detailed plans and timelines" on stopping the leak.

The information is needed before BP is allowed to change caps on the oil well.

Meanwhile, a court has rejected the government's bid to restore an offshore deepwater oil drilling moratorium.

The federal appeals court in Louisiana denied the Obama administration's request that a lower court's June order lifting the six-month moratorium be stayed pending appeal.

The three-judge panel wrote that the government had "made no showing that there is any likelihood that drilling activities will be resumed pending appeal".

Further hearings on the issue are expected.

The ruling came as BP said its operation to drill a new relief well to stop the Deepwater Horizon leak was ahead of schedule.

Storm warning

The new cap BP intends to install should make a more secure seal over the wellhead.

The company also plans to connect a third containment ship to capture more oil.

Image caption BP began drilling two relief wells to stop the Deepwater Horizon leak in May

But while the caps are being changed, the rate at which oil is spilling out of the leak will increase.

And if the third containment ship, the Helix Producer, has not been connected when the change of caps is made, there will only be one vessel capturing oil.

BP's latest moves also are part of efforts to create a system for tackling the leak that is prepared for potential hurricanes.

The US National Hurricane Center issued a warning on Wednesday about a tropical depression which has formed in the Gulf of Mexico.

Stormy weather has already disrupted efforts to contain the oil which has been leaking from the site of the Deepwater Horizon rig since April.

Adm Allen stressed the critical nature of this period of the response effort in his letter to BP Managing Director Bob Dudley, as well as demanding information on five key points:

An outline detailing production by the Helix Producer and mounting of the new cap

A plan for resuming the recovery at the riser if mounting the new cap fails

A plan for pressure testing the well and transitioning from fully collecting oil from the cap to "shutting in the well"

A plan outlining the management of oil reaching the water's surface

A timeline for the completion of the relief wells.

'Ahead of schedule'

BP says its operation to drill a relief well to stop the Gulf of Mexico oil leak is "slightly ahead of schedule". Adm Allen confirmed this during a press conference on Thursday.

Crews expect to reach the Deepwater Horizon well roughly 18,000ft (5,500m) below sea level and drill into its casing in seven to 10 days' time.

But crews will not know how much time it will take to stop the leak until they reach the well.

Adm Allen said if the oil was leaking out through different parts of the well, it would probably take until the middle of August to stop the gushing oil with mud and cement.

"If you have to exhaust all means for the ways that hydrocarbons are coming up the pipe, then that puts you into middle August," he said.

Adm Allen added that if the oil was only travelling up the well's central casing, BP might be able to stop the flow sooner.

The company began drilling the first of two relief wells on 2 May and the second on 16 May.

BP is facing massive clean-up costs and compensation claims as a result of the Gulf of Mexico oil leak.

As a result, the company has said it will look at selling some assets and attracting new investment.

The US government has been highly critical of BP's handling of the oil leak.