Skip to content

Configuring GitHub Webhooks

Webhooks send HTTP POST payloads to external URLs when repository events occur, enabling integrations with other systems.

  1. Go to Settings > Webhooks and click Add webhook.
  2. Enter the payload URL of your application.
  3. Choose the content type, usually application/json.
  4. Provide a secret token to sign payloads for verification.
  5. Select individual events or Send me everything.
  6. Click Add webhook to save.

Use the secret token to validate the signature:

const crypto = require('crypto');
const signature = 'sha256=' + crypto
.createHmac('sha256', secret)
.update(body)
.digest('hex');
  • Trigger CI/CD pipelines
  • Post messages to chat applications
  • Synchronize issues with project management tools