Welcome to HP Support Community.
Thank you for posting your query, I will be glad to help you.
It sounds like your Envy 5010 is having connectivity issues, especially with Wi-Fi Direct. Here are some troubleshooting steps you can try:
1. Reset the Printer's Network Settings
- On the printer, go to Setup > Network Settings > Restore Network Defaults.
- Restart the printer and try connecting again.
2. Connect Using Standard Wi-Fi Instead of Wi-Fi Direct
- If your home Wi-Fi network is stable, use Wireless Setup Wizard (on the printer’s touchscreen) to reconnect the printer to your router.
- Once connected, remove and re-add the printer on your computer.
3. Check WPS PIN Timeout
- The WPS PIN is usually valid for 90 seconds. If you enter it too late, it will fail.
- Try generating a new WPS PIN from Wi-Fi Protected Setup > PIN Method and enter it immediately.
4. Update Printer Firmware
- Check for firmware updates via HP Smart App or printer settings.
5. Clear Print Queue and Restart Print Spooler
- Open Services (Windows key + R → type services.msc).
- Find Print Spooler, right-click, and Restart it.
- Also, clear any stuck print jobs before trying again.
6. Try USB Connection for Setup
- If all else fails, connect the printer via USB, install it, and then switch to wireless.
I hope this helps.
Take care and have a good day.
Please click “Accepted Solution” if you feel my post solved your issue, it will help others find the solution. Click the “Kudos/Thumbs Up" on the bottom right to say “Thanks” for helping!
Asfiya03
HP Support