0

Are there still ways to fetch the MAC Address of an Android device programmatically nowadays?

I have this project, that uses Access Points to locate the indoor position of a device, and for the location data, its unique identifier is the connected device's MAC Address.

I am fetching the location from the Access points thru an HTTP request, but with that request, I am getting all the devices connected.

My goal is to create a react native mobile app that can distinguish the MAC address of the device where it runs. So that after fetching the location data from the Access Points, I can display where I am on the indoor map using the react native app.

I tried using Expo CLI, but it does not support it also. I can redo it into Java and do it in android studio if needed.

Updates starting Android 11 https://developer.android.com/training/articles/user-data-ids#mac-11-plus

Don't work with MAC Address

All suggestions are appreciated :)

  • Its already answered here, Check this *https://stackoverflow.com/questions/11705906/programmatically-getting-the-mac-of-an-android-device* – Arun Joseph Jul 05 '22 at 16:29
  • Does this answer your question? [Programmatically getting the MAC of an Android device](https://stackoverflow.com/questions/11705906/programmatically-getting-the-mac-of-an-android-device) – Arun Joseph Jul 05 '22 at 16:32
  • Please provide enough code so others can better understand or reproduce the problem. – Community Jul 05 '22 at 18:38
  • Thanks for the suggestion @ArunJoseph, but I already tried that. The app just gives me the constant value of 02:00:00:00:00:00 – confused Jul 06 '22 at 06:35

0 Answers0