To turn on Wi-Fi, go to Settings > Wi-Fi. If necessary, tap the button to turn Wi-Fi on. If networks are available, they will appear in the Choose a Network list. Tap the name of the network (SSID in technical terms) you want to connect with and enter a password if necessary.
You can turn on auto-join for networks that you regularly connect to and trust, such as your home and work Wi-Fi networks. Auto-join will automatically connect to the Wi-Fi signal whenever you are within range.

On many public networks, you may have to agree to Terms of Service as a part of the connection process. Be cautious and always assume public networks are not secure or private.