Palestinian security spotted the suspicious car at a checkpoint before the Karni crossing on Wednesday.
The occupants of the car opened fire and wounded three police officers. Police shot back, wounding two of the attackers.
Inspecting the car, police found canisters filled with 300 kilogrammes of explosives and fuel.
Security officials said the attackers planned to ram the Karni crossing and blow it up.
Several hours later, Palestinian security officers carried the blue canisters a short distance away and detonated them, setting off a huge blast.
The crossing is the main entry point for food and other vital products into Gaza.
Israel has frequently closed it, citing threats of attacks, causing shortages in Gaza and also harming Israeli farmers, for whom Gaza is a prime market.
The crossing is the main entry
point for goods into Gaza
When the gunfire began on the Palestinian side on Wednesday morning, Israel closed the crossing.
After nightfall on Wednesday, the Israeli military would not say when the crossing would be reopened.
It was not clear who would have an interest in bombing the crossing and triggering a humanitarian crisis in Gaza.
A statement from the office Mahmoud Abbas, the Palestinian president, said the attempt was aimed at "increasing the suffering of our people".
But the statement did not blame anyone.There was no claim of responsibility.
In the West Bank on Wednesday, Israeli forces shot and killed a Palestinian during a raid in a village, the military and Palestinian witnesses said.
The dead man was named as Amir Howshiya, 22, an activist from the Al-Aqsa Martyrs Brigades, which is loosely affiliated to the Fatah party of Abbas, sources said.
Amir Howshiya was killed during
an Israeli raid in the West Bank
He was killed when clashes broke out between armed men from the brigades and Israeli troops in the town of Al-Yamun, west of the northern West Bank city of Jenin, the sources said.
Israeli troops, backed by 30 military vehicles stormed into the village and surrounded a number of buildings in an attempt to arrest of a wanted member of the Islamic Jihad movement.