The attack early on Thursday killed a Hamas fighter and a policeman, and wounded six officers from the Palestinian coastal police, four seriously.
Four other people were also wounded, hospital officials said.
It was unclear where the shells came from. Palestinian officials said either Israeli navy gunboats or tanks fired the shells.
Israel has denied any shelling from either sea or land.
Hospital officials identified the dead Hamas fighter as Hussam Hijazi.
Palestinians said Hamas fighters were operating in the area at the time.
Israel has been massing troops across from northern Gaza, and some moved across the border in what appeared to be the start of an operation to create a buffer zone there to move Israeli cities out of Palestinian rocket range.
Last month eight Palestinians were killed in an explosion on the Gaza beach.
Palestinians said Israeli shelling was responsible, but Israel denied it.
On Wednesday, Palestinian resistance fighters fired a rocket at the Israeli city of Ashkelon for the second day in a row, and Israel pledged to respond harshly.
In Bait Hanun, Muhammad Kaskeen, a Palestinian from the Ramattan news agency working with an Aljazeera crew, was wounded by gunfire when the group was caught in the crossfire between Palestinian fighters and Israeli tanks.
A medical official said Kaskeen suffered serious head injuries but was in stable condition.
In Gaza City, witnesses said attackers in a car without licence plates shot and seriously wounded a university professor.
He died later in a Gaza hospital, a health official said. It was not known who the assailants were.