_____ _               _               _____ ____  
 / ____| |             | |             | ____|___ \ 
| (___ | |__   __ _  __| | _____      _| |__   __) |
 \___ \| '_ \ / _` |/ _` |/ _ \ \ /\ / /___ \ |__ < 
 ____) | | | | (_| | (_| | (_) \ V  V / ___) |___) |
|_____/|_| |_|\__,_|\__,_|\___/ \_/\_/ |____/|____/ 

Step 4: Network Location Services

There are two different ways that a mobile device can detect its location: using a built-in GPS chip or triangulating based on cell towers and WiFi access points. This latter method is called "Network Location" and is usually provided to the Android system by Google's play services. If someone is going No GApps, however, this normally means that they either use GPS or nothing.

Enter UnifiedNLP, by the creator of the microG project. UnifiedNLP can connect to a number of location-providing backends to tell the Android system its network location. It achieves this by pretending to be the Play Services, the app that the system looks to for the location. Since microG also pretends to be this app, UnifiedNLP is packaged with microG and *does not need to be downloaded separately if you are already using microG*. For those who do not wish to use microG, however, there is a separate download available that only provides the network location.

UnifiedNLP on F-Droid

As for location backends, I recommend using the Mozilla backend if you do not mind the location calculation being done online, otherwise you can use the Déjà Vu backend combined with the device's GPS. Déjà Vu remembers locations associated with various WiFi APs and cell towers and recalls that information if it recognizes them again. Otherwise, something else (like another backend or the GPS) needs to determine the device's location.

Mozilla backend on F-Droid Déjà Vu backend on F-Droid

Other backends are also available on F-Droid, if one of the ones I recommended does not work well in your area.