I have found that this issue is usually due to ISP and/or router DNS issues and not the device itself.
I suggest the following to try and resolve this issue...
Modem/Router:
1. If you have manually added DNS server IPs to your router, write them down, remove them, choose DHCP and let your ISP choose the DNS servers automatically.
2. Power cycle your modem/router.
iOS Device:
1. Close all running apps, including Safari.
2. Settings > Safari > Advanced > Website Data > Remove All Website Data.
3. Update to the latest iOS.
4. Perform a hard reset.
Let me know if that helps,
C