It may have been a while since you set up your iOS device (iPhone / iPad / iPod touch) to connect to an wireless network, like your router's at home or at work. Your iPhone can support and remember multiple networks, so connecting it to another network won't reset anything. It will just switch network when you change location, and the process is completely transparent! Tip: if you need internet access for your PC / Mac, you can use your iPhone as Wi-Fi hotspot.
First, make sure that your device's wireless radio is in fact on: swipe your finger from the bottom of the screen, upward, and you should see the mini control panel just like on the screenshot. If you've upgraded to iOS 9, it will look exactly the same. If the wireless network symbol is highlighted, the feature is on. If not, tap on it to turn it on. Remember that: it's quicker than going through Settings!
Click on the Home button to minimize all your apps, and tap on the gear icon to launch the Settings app. From its first screen, tap on Wi-Fi. Notice that the button will also show the name of the wireless network to which you're currently connected - if you haven't joined any, it will simply say "Not Connected".
On the next screen, your iPhone / iPad will scan for available wireless networks in the area, and automatically sort them from strongest to weakest signal. If your router is not broadcasting its "SSID" (you can change your wireless network name), tap on the Other button at the bottom to types its name. Either way, enter that network's password. Then, tap on Join in the top right corner.
If you supplied the correct password, your phone or tablet will switch from showing 3G / 4G / LTE at the top, to showing the wireless network icon (contrast this screenshot with the one in step 3). On the current screen, you'll see the name of the network to which you're connected, with a checkmark. To connect to a different network, tap on its name. You're only asked for a password if it is your first connection to it, or if the password has changed.