Probably your device may not be connected to the internet.
Connecting to Wi-Fi is the first part and then getting connected to the Internet is the second
- If you are connected to a Wifi, doesn't necessarily mean you are connected to the internet. If you are not connected to wifi could be a problem with iPhone settings or Router/Modem Settings
- If you are not connected to the internet is the sole issue of Router / Modem Settings. Contact your ISP immediately
Internet Over Wi-FI: Contact your ISP (Internet Service Provider), the agency that provided the Internet Service on your Modem/Router to you
Recommended settings for Wi-Fi routers and access points
For your Internet connection.
- Over Cellular/Mobile: contact your Carrier (Cellular Service Provider). The agency that issued the SIM to you
- Over Wi-Fi: Contact your ISP (Internet Service Provider), the agency that provided the Internet Service on your Modem/Router to you
However --> Connect iPhone to the Internet - Apple Support