DIAGNOSIS The printer's initial Wi-Fi setup is failing to find or connect to your network. Yeah, this one's common, especially if your router is broadcasting a 5GHz network or using certain security settings.
FIX First, try a wired connection. Plug an ethernet cable from your router directly into the printer. Once it's on the network via cable, you can often then go into the printer's Embedded Web Server (type its IP address into a browser) and configure the Wi-Fi settings manually. Alternatively, you can use the HP Smart app on your phone. Make sure your phone is connected to the 2.4GHz band of your Wi-Fi, then use the app to set up the printer—it sometimes bypasses the flaky built-in scanner.
IF THAT DIDN'T WORK The network module itself might need a reset. Turn the printer off. Unplug it from the wall for a full 60 seconds. While it's off, press and hold the WirelessCancel button simultaneously, then plug the power cord back in. Keep holding the buttons for about 20 seconds after power is restored, then release. This performs a full network reset.
HEADS UP This printer does not support connecting to Wi-Fi networks that require a login portal (like hotels or some apartments). It also has known issues with WPA3 security; if possible, set your router to use WPA2 for the 2.4GHz band during setup.