Simplest way to check for an active Internet Connection on iOS

Sometimes we need to check synchronously, if there is an internet connection. For instance, when an app totally depends on internet connection. This is the simplest way to check internet connection on iOS app synchronously without using Reachability class:

Taken from here.

Instead of Google it is better to use another lightweight website. But I use, since it is always online and reliable and not very heavy page.

Leave a Reply

Your email address will not be published. Required fields are marked *