Eleven people were injured but a threatened tsunami rose to only a metre in height.
No abnormalities were reported in nuclear power plants, the government said.
Train services were suspended and an airport closed, but both actions were only temporary.
The Japan Meteorological Agency said the tremor was likely to have been an aftershock of the magnitude 9 quake that devastated the region on March 11, 2011.
The agency warned of an aftershock from Friday's quake of up to magnitude 6 within a week.
The agency issued a warning immediately after the quake originated in the Pacific. Tidal waves of up to a metre reached coastal areas in Miyagi, Iwate and Fukushima prefectures, and people in many of the quake-hit areas were evacuated.
The agency lifted all tsunami warnings about two hours after the quake.
The Tokyo Electric Power Co said it instructed workers at the Fukushima Daiichi nuclear plant, which suffered meltdowns after the 2011 quake, and the nearby Daini plant to move to higher ground.
Prime Minister Yoshihiko Noda, who cancelled a campaign speech in Tokyo and returned to his office to oversee the government's response, told reporters he instructed his staff to "gather information and stay on alert".
The focus of the quake was 240 kilometres off the Pacific coast of Miyagi prefecture at a depth of 10 kilometres.
The cities of Sendai, Iwanuma and Ishinomaki in Miyagi prefecture, Rikuzentakata in Iwate prefecture and Hachinohe in Aomori prefecture among others urged residents in coastal areas to evacuate.
The Aomori government said around 220 households in the town of Gonohe suffered a power outage following the quake.
Services on the Tokaido, Tohoku, Joetsu and Nagano shinkansen bullet train lines were suspended temporarily, according to the operator.
Sendai airport near the coastline in Miyagi grounded all flights, while Narita airport near Tokyo briefly closed runways.