The Andaman and Nicobar archipelago is prone to earthquakes. (Representational)

A medium intensity earthquake of magnitude 5.8 hit the Andaman and Nicobar islands on Wednesday morning.

The earthquake, which had its epicentre in the Andaman islands, occurred at 6:09 am, the National Centre for Seismology said.

The Andaman and Nicobar archipelago is prone to earthquakes.