# GitHub Actions: workflow does not run on push / pull_request / workflow_dispatch button missing

**Code:** `workflow not triggering` · **Category:** CI/CD · **Seen on:** GitHub Actions

A workflow file exists but no run appears — the trigger filters do not match, the file is not on the right branch, or the workflow is disabled.

## Meaning

There is no error message, which makes this confusing. Check, in order: the file is in `.github/workflows/` on the branch GitHub reads (for `workflow_dispatch` and `schedule` the default branch), the `on:` events and `branches`/`paths` filters match your change, the workflow is not disabled, and commits from a workflow using `GITHUB_TOKEN` do not trigger other workflows.

## Common causes

- `workflow_dispatch` / `schedule` file not on the default branch
- `branches` / `paths` filters exclude the change
- YAML error so the workflow never registered
- Push made with `GITHUB_TOKEN` (it does not trigger new runs)
- Workflow disabled (inactivity of 60 days on schedules) or Actions disabled for the repo

## Quick fix

1. Open Actions → the workflow → check for a "disabled" banner or YAML error
2. Compare `on:` filters with the files and branch you changed
3. Use a PAT or GitHub App token if one workflow must trigger another

## Detailed fix by platform

### GitHub Actions

1. Minimal trigger: `on: { push: { branches: [main] }, pull_request: {}, workflow_dispatch: {} }`
2. Merge the workflow into the default branch before using `workflow_dispatch`

## Code examples

### Triggers that rarely miss

```yaml
name: CI
on:
  push:
    branches: [main]
  pull_request:
  workflow_dispatch:        # shows the "Run workflow" button (file must be on the default branch)
```

## How to diagnose

1. **Location** — Is the file on the right branch?
2. **Filters** — Do branches/paths match?
3. **State** — Disabled or YAML error?

---
Source: [WhatIsMyError](https://whatismyerror.com/errors/cicd/gha-workflow-not-triggering)
