There likely are multiple causes to this problem. Mine was the Access Point Name (APN) protocol was set to IPv6. Creating a new APN with protocol and roaming protocol set to IPv4 fixed mine.
Go to Settings/More Networks/Mobile Networks/Access Point Names and see what you're using. If IPv6...