Messages delayed by days

Messages delayed by days

In the past week I have sent messages that took 2-3 days to be received. Some are being received right away, some are taking hours and some are taking days. What is going on? This is happening with iPad and Iphone.