What it is: The VL53L0X measures distance with a tiny invisible laser, timing how long light takes to bounce back (time-of-flight). It's accurate from ~3 cm to ~1.2 m and, unlike an ultrasonic sensor, has a narrow beam and doesn't care about soft surfaces.
How it works: I2C device at address 0x29. The ST/Adafruit library fires the laser and returns the range in millimetres. Shares SDA/SCL with the OLED.
Wiring (shared I2C bus with the OLED):
VL53L0X SDA -> GPIO4
VL53L0X SCL -> GPIO5
VL53L0X VIN -> 3V3
VL53L0X GND -> GND
OLED VCC=3V3, GND=GND, SDA=GPIO4, SCL=GPIO5
Libraries: "Adafruit VL53L0X" (installs "Adafruit BusIO"), plus "Adafruit SSD1306" and "Adafruit GFX Library".
On screen / Serial: distance in mm, or "out of range" when nothing is in view. Move your hand toward and away from it.
Gotchas: Keep the small window clean and unobstructed. Bright sunlight and shiny/mirror surfaces reduce range. Address is 0x29; to use several, you toggle each one's XSHUT pin and reassign addresses (advanced).