If you get an error code while downloading and installing Windows updates, the Update Troubleshooter can help resolve the problem. Make sure you have internet access, then run or download the Update Troubleshooter version that matches your version of Windows:
Windows 10: Select Start > Settings > Update & Security > Troubleshoot, then select Windows Update under Get up and running, and then select Run the troubleshooter.
When it's done, it's best practice to restart your device. Then check for new updates. Select Start > Settings > Update & Security > Windows Update, then select Check for updates and install any available updates.
If the problems aren't all resolved, try running the troubleshooter again to check for additional errors. Or see Fix Windows Update errors and follow the troubleshooting steps.