ASHKELON, Israel (Reuters) - Palestinian militants in Gaza fired a rocket into Ashkelon on Israel’s Mediterranean coast on Friday, blowing out the windows of an apartment block and damaging parked cars in a residential area of the city.

No one was injured in the blast. But the attack ended over a year of calm for the city closest to the enclave ruled by the Islamist Hamas movement and it was likely to trigger a military response by Israel.

A police spokesman said the rocket was a 122 mm Chinese-made Grad, with a heavier payload and greater range than the crude, homemade rockets Gaza militants were launching daily until Israel’s three-week military offensive into Gaza 18 months ago.

“As you see, hundreds of people live here. It’s just luck that no one was killed,” said Ashkelon mayor Benny Vaknin.

Ashkelon, with a population of 125,000, lies on the coast about 12 km (7 miles) north of the Gaza Strip. The mayor said it was the most serious attack on the city since Israel ended its offensive in January 2009 and Gaza rocket fire was suppressed.

“Israel takes the firing on Ashkelon very seriously,” Israeli Prime Minister Benjamin Netanyahu said in a statement.

The Foreign Ministry said Israel had the right to respond “at a time and in a way it deems proper.” Israel would also lodge a protest with the United Nations for an attack targeting civilians in violation of international law, it said.

U.N. Special Coordinator Robert Serry said in a statement “indiscriminate rocket fire against civilians is completely unacceptable and constitutes a terrorist attack.”

Hamas must not allow militant violence to undermine progress in the talks between Israel and the Palestinians, he said.

PEACE TALKS

No group in Gaza claimed responsibility for Friday’s attack.

Hamas has said it is trying to stop militants from firing at Israel, but smaller groups have continued to launch rockets.

Friday’s strike coincided with diplomatic efforts to persuade Palestinian President Mahmoud Abbas that he should advance from indirect negotiations to direct talks with Israel in pursuit of a Middle East peace pact -- which Hamas and other militant and armed Islamist groups in Gaza oppose.

Abbas, denounced by Hamas as a Western pawn, has been negotiating with Netanyahu indirectly for two months via a U.S. mediator and is under U.S. pressure to upgrade to face-to-face talks before the end of September.

On Thursday, Arab League foreign ministers meeting in Cairo gave Abbas the green light to engage in direct peace talks with Israel when he feels the time is right.

Hamas rejected the decision, calling it a “political sin.”

The attack on Ashkelon also coincided with a demand from the U.N. Human Rights Committee in Geneva that Israel lift its military blockade of Gaza and let an independent fact-finding mission investigate its raid on an aid flotilla on May 31 in which nine activists were killed by Israeli commandos.

Israel has since eased restrictions on imports of food and consumer goods to Gaza but insists that the naval blockade must stay in place to help prevent shipment of weapons, such as Grad missiles, to hostile groups in the enclave.

There has been sporadic, and erratic, rocket fire from Gaza since Israel’s Operation Cast Lead ended, mostly at smaller Israeli towns closer to the border.

Israeli forces usually respond by launching air strikes against militant targets in Gaza.