Skip to content
Latchkey

GitHub Pages "Deployment request failed (no artifact)"

actions/deploy-pages publishes a previously uploaded github-pages artifact. If the build job never ran upload-pages-artifact, or the artifact name is wrong, the deploy has nothing to publish and fails.

What this error means

The deploy-pages step fails because it cannot find a github-pages artifact for the run, even though the build appeared to succeed.

github-actions
Error: Deployment request failed
No artifact named "github-pages" was found for this workflow run.

Common causes

upload-pages-artifact step missing

The build job did not upload the site with actions/upload-pages-artifact, so the deploy job has no artifact.

Deploy job does not depend on build

The deploy job runs before or independently of the build job, racing the artifact upload.

How to fix it

Upload the artifact and order the jobs

  1. Add actions/upload-pages-artifact in the build job pointing at the built site directory.
  2. Make the deploy job depend on the build job with needs.
  3. Re-run; deploy-pages will find the github-pages artifact.
.github/workflows/pages.yml
  build:
    steps:
      - uses: actions/upload-pages-artifact@v3
        with:
          path: ./_site
  deploy:
    needs: build
    steps:
      - uses: actions/deploy-pages@v4

How to prevent it

  • Always pair upload-pages-artifact in build with deploy-pages in a dependent deploy job.
  • Keep the artifact name as the default github-pages unless you have a reason to change it.

Frequently asked questions

What causes ""Deployment request failed" (no artifact)"?
The build job did not upload the site with actions/upload-pages-artifact, so the deploy job has no artifact.
How do I fix "Deployment request failed" (no artifact)?
Upload the artifact and order the jobs

Related guides

References

Latchkey auto-heals failures like this one - detected, fixed, and retried without you. Start free → 30-day trial · No credit card