Hey everyone,

I dont know very much about bluetooth from a development point of view. I was just wondering is there a way to get an ID (phone number etc) of a bluetooth phone similar to how you would an IP address from a computer/device.

For example, a bluetooth reader on the wall which only allows final year students into the lab. The phone could be used as ID -when the person scans his phone over the bluetooth reader the 'ID' of the phone is checked against a database and access is denied/granted. Is this possible?

Any help is much appreciated :)

Thanks

Dani AI

Generated

Short answer: you cannot reliably read a user’s cellular phone number over Bluetooth. Bluetooth exposes device identifiers (a hardware address, often called BD_ADDR) and service-level identifiers, but modern mobile platforms and Bluetooth privacy features make using a radio-level address as a stable “ID” brittle.

Technical points that matter for design and prototyping:

  • A Bluetooth device has a hardware address (BD_ADDR), but platform and privacy changes (randomized/resolvable private addresses in BLE, and OS‑level restrictions) mean the same phone may present different addresses over time or not expose them to third‑party apps. See Android’s Bluetooth docs for current platform rules (Android Bluetooth guide) and Apple’s CoreBluetooth model for how iOS exposes peripherals ().
  • Remote access to phonebook or phone number requires explicit pairing and user consent (and specific profiles), so it is not a silent or universal ID channel.
  • Discovery/advertising behavior is controlled by the phone and by OS limitations; relying on passive scanning in crowded public spaces produces collisions and missed detections.

Practical alternatives (for lab access or ticketing):

  • Use an app on the phone that authenticates to a backend and presents a short‑lived credential to the gate reader (QR code, NFC tap, or a BLE advertisement containing a signed ephemeral token). Design tokens so the reader can verify them offline (public‑key signature) or quickly via server. A signed JWT is a common choice for self‑contained tokens (see RFC 7519).
  • NFC or on‑screen QR codes are simpler and more robust in crowded environments than passive Bluetooth scanning.
  • If BLE is required, implement an app that actively advertises a time‑limited token; test platform advertising limits (especially on iOS) first.

Prototype tips:

  • Use a Raspberry Pi + BlueZ or a development phone to prototype scanning/advertising; test in realistic densities for false positives and battery impact. Useful starting points: BlueZ (https://www.bluez.org/) and Python BLE libraries for quick experiments.

Recommended Answers

All 3 Replies

I suppose it is possible, but not through phone numbers (to the best of my knowledge). A bluetooth phone and matched device must be set up to work together, but once they're configured they can pair automatically when in range. This could be your authentication.

This isn't a very practical idea:
1. Not everybody has Bluetooth phones.
2. Most people don't leave their bluetooth on because it uses battery.
3. Most phones will only be discoverable for about 30 seconds, and only when you enable it. So it would be the responsibility of the phone to connect to your security system.
4. People break/change phones
5. This would be expensive. The custom built system used to do this, and the man-power to maintain the database would be more expensive than just setting up an off-the-shelf security card reader or a keypad lock.

Thanks OlyComputers,
Very comprehensive and helpful post.

I was thinking about a ticket booking system (for rail tickets) using the phone to pay and be 'the ticket' using bluetooth for my final year project. I have scraped the idea heh. Appreciate your time

That example of use makes more sense, but since the scale is much larger most of the issues would be exaggerated. Not to mention the fact that bluetooth has a potential range of 30-100'. In a train station environment it would be virtually impossible to keep "tickets" straight when you have 5-10 people at a time in close proximity to the door and dozens within bluetooth range. There might be something simpler, like a booking system that sends a confirmation number via text message to the cell phone, and that's all you need to board the train. Directory assistance services do something similar by texting you the number you just requested for a record, so it's definitely possible.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.