When using your Mac with Wi-Fi, you have the option for OS X o remember your Wi-Fi network so when you are in the vicinity of this hotspot, you will seamlessly connect to it. While convenient, this can sometimes be a burden, especially if an otherwise preferred hotspot is running slowly or showing other problems.
For example, if you have two hotspots that you use in the vicinity of your work, then you may usually connect to one that gives the strongest signal; however, if you regularly get IP address conflicts, or if this hotspot’s connection is somehow slower than another one for the time being, then you may prefer to connect to your secondary hotspot. Granted you can do so by selecting it in the Wi-Fi menu; however, if you restart your system or otherwise disconnect from Wi-Fi, when your system reconnects it may choose the problematic network again.

Drag Wi-Fi hotspots higher in the list to give them priority over others. You can also remove hotspots to prevent automatic connections to them.
There are two easy solutions to this type of problem. The first is to simply prioritize the network connection so the preferred one is always tried first whenever you lose your connection:
1. Open the Network system preferences.
2. Select the Wi-Fi connection in the left-hand list.
3. Click the Advanced button at the bottom of the window.
4. Choose “Wi-Fi” from the list of tabs at the top of the drop-down panel.
5. Drag your preferred Wi-Fi network above others in the list.
In addition to removing your networks, you can use some of the settings in this panel to prevent your Mac from automatically remembering future networks you connect to, and also require administrator authorization to change your system’s Wi-Fi status. If you are at all concerned about the security of your Wi-Fi connection and want to ensure your Mac stays on a designated Wi-Fi network, then you can check these options to help ensure the Wi-Fi settings do not change.