Seismologists said that many aftershocks were expected, and called on people to keep calm and follow directions given by authorities.
"There have been aftershocks and more will follow because the epicentre was close to the surface," Gerasimos Papadopoulos, head of the Athens Geodynamic Institute's research centre, said.
"Local authorities must carry out checks to see which buildings present problems."
The Geodynamic Institute said the quake struck at 3.25pm (1225 GMT) with an epicentre on land, some 205km west of Athens, in the northwestern Peloponnese near the port city of Patras.
Greece is one of the world's most earthquake-prone countries.
The fire department said rescue crews were working to free a family of five people trapped beneath a collapsed house in the village of Fostaina, about 30km south of Patras.
The department had also sent rescue crews to another collapsed house in the village of Vartholomio where people were believed to be trapped.
Emergency services said two people in the province of Ahaia were injured by a falling roof, and one person was struck by falling rocks at a beach on the island of Lefkada.
Local media reported parts of Patras were without electricity, while collapsed and damaged houses were reported from several areas of southwestern Greece.
Papadopoulos said anyone in the area noticing damage to their building should contact a civil engineer or authorities before attempting to enter the building.