On the failed device, open the Autopilot diagnostics page and note which phase and step were running when the code appeared.

In the management console, confirm the device is in the group the Autopilot profile is assigned to.

Check every app assigned as required during provisioning still exists, has a valid install file, and is assigned to the same group.

Check network access from the provisioning network to the management and download endpoints, with no proxy sign-in step in between.

Remove and reimport the device hardware hash if the profile still does not apply, then reprovision from a clean start.