Hi,
If you are using it via USB cable or Wi-Fi:
Go to Start > Settings > Bluetooth and devices, find the printer > press Enter ..., select Remove devices.
After removing, if it's via USB, disconnect the printer.
Open the command prompt (admin) and run the commands: sfc /scannow and dism /online /cleanup-image /restorehealth, wait for the process to finish and restart the computer. After restarting, you will download the offline driver installer from the link below and follow the instructions:
The link above is for the printer driver provided by HP.
After finishing, check if the scanner was installed as well. If not, go to Start > Settings > Bluetooth & Devices > Printers & Scanners > Add devices and see if the scanner appears. Click Add or Connect.
If the answer is helpful, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".
Note: Please follow the steps in our documentation to enable email notifications if you want to receive the related email notification for this thread.
Thanks