LONDON - The United Kingdom (UK) was rocked by an earthquake last night, with people reporting “shaking” from South Wales to the West Midlands.

Google’s Android Earthquake Alerts System said the quake was 4.2 magnitude, while the European-Mediterranean Seismological Centre (EMSC) put it at 3.8 magnitude.

It occurred at a depth of two kilometres at 11.59pm, the EMSC said – putting the location as 12km (7.45 miles) north of Rhondda.

Many reported feeling the walls of their homes “shaking”, while others claimed the quake was reminiscent of “a bomb going off”.

“I’m in Rhymney and felt the house shake, looked online to see if anyone else did ... and it was an earthquake in South Wales. I think I need a change of trousers,” tweeted @KrissOttley.

Posting to Facebook, user Danielle Morgan said: “It definitely felt a lot worse than a light shaking in Ebbw Vale. We thought someone had crashed into the cars on our drive. Frightening! Brought the whole estate out wondering what was going on! The whole house shook to the core.”

Responding to her post, Jason Humphrys wrote: “I heard a loud bang that sounded like a bomb just went off then my entire kitchen shook, my cat was frightened — it was weird, it only lasted seconds but it left an impact.”

Weighing in on the conversation, Hayley Ann said: “My bed moved side to side ... I thought it was collapsing beneath me. Didn’t feel light at all,” while Helen Caswell added: “Our whole house shook in Rassau, Ebbw Vale and woke my husband up!! Really frightened us.”

Though centred on South Wales, the shocks were reportedly felt as far away as Dudely and Wolverhampton.

Katy Alexandra Jack tweeted: “Imagine, I just felt this all the way in Dudley, West Midlands.”

“A very shallow magnitude 3.8 earthquake was reported late at night near Merthyr Tydfil, Wales, United Kingdom,” reported.

“Shallow earthquakes are felt more strongly than deeper ones as they are closer to the surface.

“Based on the preliminary seismic data, the quake was probably felt by many people in the area of the epicentre. It should not have caused significant damage, other than objects falling from shelves, broken windows, etc.”

“In Merthyr Tydfil (pop. 43,800) located 5 km from the epicentre, and Aberdare (pop. 31,100) 6 km away, the quake should have been felt as light shaking.

“Weak shaking might have been felt in Rhonnda (pop. 59,500) located 12 km from the epicentre, Ebbw Vale (pop. 33,100) 16 km away, Tonypandy (pop. 62,500) 16 km away, and Pontypridd (pop. 30,400) 20 km away.

“Other towns or cities near the epicentre where the quake might have been felt as very weak shaking include Newport (pop. 306,800) located 37 km from the epicentre, Cardiff (pop. 447,300) 37 km away, and Swansea (pop. 300,400) 38 km away.”