Blog · Tutorial

How to deploy from GitHub.

To deploy from GitHub, connect your repository to a deployment platform through a GitHub App, choose a branch, and let webhooks trigger a new build on every push. This guide explains each piece and the options.

Published Sep 22, 2026Updated Sep 25, 20263 min read

key takeaways
  • A GitHub App grants scoped repo access
  • Webhooks tell the platform when you push
  • One branch = production; PRs = previews
  • Verified webhook signatures stop fake deploys
tl;drrunex

How it works

How does deploying from GitHub work?

Access, event, build, release. On Runex, access comes from the Runex GitHub App.

  1. You

    Grant access

    Install the platform's GitHub App.

  2. GitHub

    Send a webhook

    On every push and pull request.

  3. Platform

    Build the commit

    After verifying the webhook.

  4. Platform

    Release

    Swap traffic once it's healthy.

Compare

GitHub App vs OAuth app vs GitHub Actions: which should you use?

A GitHub App is the most secure way to connect a platform. Actions is for running your own pipeline.

GitHub App vs OAuth app vs GitHub Actions: which should you use?
RecommendedGitHub AppUser tokenOAuth appYour pipelineGitHub Actions
Acts asIts own identityA specific userA workflow in your repo
Repo accessOnly repos you pickEverything the user can seeThe repo it runs in
Survives a user leavingYesNoYes
Runs your appThe platform doesThe platform doesNo, deploys elsewhere

Practices

What are the best practices for GitHub deployments?

Five habits for safe push-to-deploy. Pair push-to-deploy with instant rollbacks so a bad release is one click from undone.

  • Grant the App access to only the repositories you deploy
  • Protect the production branch and require pull request reviews
  • Use preview deployments to test every pull request
  • Keep secrets in the platform's environment variables, not in the repo
  • Make sure you can roll back to a previous deploy in one step

On Runex

How do you deploy from GitHub on Runex?

Install the App, pick a branch, push. The GitHub deployment guide walks through it step by step.

  1. You

    Install the Runex GitHub App

    On the repos you'll deploy.

  2. You

    Pick repo and branch

    Usually main.

  3. Runex

    Deploy on push

    Webhooks verified.

  4. Runex

    Preview each PR

    A URL per pull request.

FAQ

Frequently asked questions

Short answers to related searches.

What is a GitHub webhook?

An HTTP request GitHub sends to a URL you register whenever an event happens, such as a push or a new pull request.

Is a GitHub App better than a personal access token?

Yes, for deployments. A GitHub App has its own identity and only the repos you grant, and it keeps working when a team member leaves.

Can I deploy only one branch automatically?

Yes. Most platforms deploy one branch, often main, to production and create previews for pull requests.

Do I need GitHub Actions to deploy from GitHub?

No. A deployment platform with a GitHub App builds on push by itself. Actions is useful for tests you want to run first.

Next step

Put it into practice.

Deploy an app from GitHub on Runex and get a live HTTPS URL. Free to start.