# GitHub's AI Scan spends your Copilot allowance first. Your security team holds the button.

> GitHub AI Scan is the AI-powered security scanner. It went GA for pull requests on October 15, 2026, entered preview for whole repositories on October 28, and gained a REST API on November 13 and bulk start for 20 repositories on November 16. It needs no Copilot license, but it bills Code Security AI credits, and those draw on your Copilot entitlement's included allowance first. Here's how the meter works, what a scan can cost at its documented ceiling, and the budget to set before anyone presses bulk start. It also covers how to spot scan spend in FinOpsAid before it's mistaken for developer overspend.

Source: https://finopsaid.com/blog/github-ai-scan-code-security-ai-credits/  
Published: 2026-11-17  
Updated: 2026-11-17  
Author: FinOpsAid  
Publisher: FinOpsAid (https://finopsaid.com)

---

The person who can spend your organization's Copilot allowance is no longer just a developer with a Copilot seat. Since October, it's also anyone with write access who starts an AI Scan, and none of them needs a Copilot license.

Part of the guide: [GitHub Copilot AI credits](https://finopsaid.com/solutions/github-copilot-ai-credits/) →

GitHub AI Scan is an AI security scanner that sits next to CodeQL. It finds vulnerabilities in languages CodeQL doesn't cover, and some that rule-based analysis misses in languages it does. It bills **Code Security AI credits**, a separate SKU under Advanced Security. The detail most budgets will miss is the order of consumption: "Included AI credits from a GitHub Copilot entitlement are used first. After those run out, or if none exist, usage is metered under the applicable budgets" ([GitHub Docs](https://docs.github.com/en/code-security/concepts/code-scanning/ai-scan-for-repositories), November 2026).

## Four releases in five weeks

| Date | Change | Status |
|---|---|---|
| Oct 15 | AI Scan for pull requests | Generally available |
| Oct 28 | AI Scan for repositories (default-branch backlog) | Public preview |
| Nov 13 | REST API for the `repository_scan` setting | Public preview |
| Nov 16 | Start AI Scans on up to 20 repositories at once | Public preview |

Both modes are on github.com and GitHub Enterprise Cloud with data residency, not on GitHub Enterprise Server. The enterprise AI Scan policy defaults to "Not allowed", so nothing runs until an enterprise owner allows it.

## Two modes, two spending patterns

**AI Scan for pull requests** runs automatically. A scan happens "when a pull request is created and after each new commit", for pull requests that change code in a language or framework CodeQL doesn't cover, such as PHP, Shell, Terraform, Dockerfiles, JSP or Blazor. It skips forks and Dependabot pull requests. Its findings are advisory: they don't fail the check or block a merge.

That makes PR scanning a *usage-shaped* cost. It scales with how often people push to pull requests that touch those languages. A team that pushes twenty small commits to a Terraform pull request pays for twenty scans, not one.

**AI Scan for repositories** runs on demand. Someone with write access starts it, and it scans the latest commit on the default branch. There's no schedule and no scan on push, and merging a fix doesn't trigger a rescan. It's a *decision-shaped* cost. Spend happens when a person decides to press the button, and since November 16 they can press it for 20 repositories at once.

## What one scan can cost

GitHub doesn't publish a per-scan price. It does publish a ceiling: for repository scans, "detection steps are capped at 30 minutes and 150,000 AI credits". GitHub prices AI credits at $0.01 each elsewhere in its billing docs. The Advanced Security billing page doesn't restate the rate, so treat the dollar figures below as our arithmetic, not GitHub's.

<figure>
<svg viewBox="0 0 720 250" role="img" aria-labelledby="ais-t ais-d" xmlns="http://www.w3.org/2000/svg">
<title id="ais-t">Documented ceiling for AI Scan for repositories, one scan versus a 20-repository bulk start</title>
<desc id="ais-d">Two rows. One repository scan has a documented detection ceiling of 150,000 Code Security AI credits, which is 1,500 dollars at 0.01 dollars per credit. A bulk start across 20 repositories has a combined ceiling of 3,000,000 credits, or 30,000 dollars. These are ceilings for the detection steps, not typical costs. GitHub does not publish typical per-scan consumption.</desc>
  <text x="0" y="14" font-family="JetBrains Mono, ui-monospace, monospace" font-size="9.5" letter-spacing="1.6" fill="#586675">DETECTION CEILING · NOT A TYPICAL COST</text>
  <text x="0" y="44" font-family="JetBrains Mono, ui-monospace, monospace" font-size="10" fill="#8A99A6">ACTION</text>
  <text x="300" y="44" font-family="JetBrains Mono, ui-monospace, monospace" font-size="10" fill="#8A99A6">AI CREDITS (MAX)</text>
  <text x="530" y="44" font-family="JetBrains Mono, ui-monospace, monospace" font-size="10" fill="#8A99A6">AT $0.01 / CREDIT</text>
  <rect x="0" y="54" width="720" height="56" rx="3" fill="#121A22"/>
  <text x="14" y="80" font-family="Inter, system-ui, sans-serif" font-size="11.5" fill="#E9EFF3">Scan one repository</text>
  <text x="14" y="98" font-family="Inter, system-ui, sans-serif" font-size="10" fill="#8A99A6">30-minute detection cap</text>
  <text x="300" y="86" font-family="JetBrains Mono, ui-monospace, monospace" font-size="12" fill="#E9EFF3">150,000</text>
  <text x="530" y="86" font-family="Inter, system-ui, sans-serif" font-size="12" fill="#E9EFF3">$1,500</text>
  <rect x="0" y="120" width="720" height="56" rx="3" fill="#0F161D"/>
  <rect x="0" y="120" width="4" height="56" fill="#F5A524"/>
  <text x="14" y="146" font-family="Inter, system-ui, sans-serif" font-size="11.5" fill="#E9EFF3">Bulk start, 20 repositories</text>
  <text x="14" y="164" font-family="Inter, system-ui, sans-serif" font-size="10" fill="#F5A524">one click, since Nov 16</text>
  <text x="300" y="152" font-family="JetBrains Mono, ui-monospace, monospace" font-size="12" fill="#F5A524">3,000,000</text>
  <text x="530" y="152" font-family="Inter, system-ui, sans-serif" font-size="12" fill="#F5A524">$30,000</text>
  <text x="0" y="206" font-family="Inter, system-ui, sans-serif" font-size="11.5" fill="#8A99A6">Most scans should end well under the cap. The cap is what a budget has to absorb</text>
  <text x="0" y="224" font-family="Inter, system-ui, sans-serif" font-size="11.5" fill="#8A99A6">if one doesn't, and included Copilot credits are spent before any of it is metered.</text>
</svg>
<figcaption><strong>The ceiling, not the expected bill.</strong> The 150,000-credit and 30-minute caps are from GitHub's AI Scan for repositories documentation. The 20-repository bulk limit is from the November 16, 2026 changelog. Dollar figures are our arithmetic at $0.01 per AI credit. Retrieved 2026-11-17.</figcaption>
</figure>

Two things keep this from being alarming, and both are worth stating plainly. The cap is a ceiling. GitHub describes a "fixed time budget that keeps its cost bounded", and most scans of ordinary repositories should end well below it. Also, the cap applies to the detection steps. The docs don't say whether anything outside detection adds to the total.

The real risk isn't one big scan. It's the order of consumption. Included credits from a Copilot entitlement are used first. So a security manager running a bulk scan in the first week of the month can use up the allowance your developers expected to have for chat and agents. Developers then reach metered Copilot usage earlier than usual, and the overage looks like a developer problem when it started in security. That's the point of the title.

## Who gets billed

- **Organization-owned repositories** bill the account responsible for the organization's billing. In an enterprise, that's the enterprise pool, not the person who pressed the button.
- **Public repositories owned by a personal account** bill that account. If the owner has a Copilot license provided by an organization or enterprise, that organization or enterprise pays.
- **Managed user personal namespaces** aren't eligible for AI Scan at all.

Usage appears in the "AI usage" section of enterprise billing and licensing, under the **Advanced Security** product, not Copilot. Eligible repositories are public organization repositories (no active-committer license needed), and private or internal ones with GitHub Code Security or GitHub Advanced Security.

## The budget is the off switch

GitHub's own guidance is to "set a hard budget to cap metered usage" before enabling AI Scan or agentic autofix broadly. You can set SKU-level budgets for Code Security AI credits. When a hard budget leaves no credits, AI Scan "cannot produce findings" until an administrator raises the budget or a new billing cycle starts. For repository scans, GitHub warns before a scan starts if the budget is used up.

Plan for that failure mode. A security team that runs out of credits mid-month loses AI findings on pull requests, and it does so silently, because the findings are advisory anyway. Nobody's merge breaks, so nobody notices. Agree in advance whether that's acceptable, or who can raise the budget.

The November 13 API gives you the rest of the controls. `PATCH /orgs/{org}/code-scanning/ai-scan` sets `repository_scan` and `pr_scan` together, and if either change is blocked, neither applies. If an organization disables a setting, its repositories can't turn it on. Enabling it doesn't start a scan, so turning it on is a permission, not a spend.

## Catch security spend before it looks like developer spend

The failure here isn't really a big bill. It's a bill blamed on the wrong team. Security starts the scan, and the overage shows up next to Copilot. Developers get a "cut back on AI" email they did nothing to earn. Avoiding that means seeing both on the same screen, by day, which GitHub's billing pages don't do. [FinOpsAid](/about/) does.

**1. Find the line in Cost Explorer.** FinOpsAid's nightly sync stores every product and SKU line that GitHub's billing usage API returns. Once your organization uses AI Scan, its spend shows up on [Cost Explorer](/blog/how-to-read-the-cost-explorer/) under spend by product, and as its own row in the SKU detail table with gross, discount and net. Set Group by to SKU and the cost drivers card shows how much of the month it accounts for.

**2. Let the Alerts page catch a bulk start.** The [Alerts page](/blog/how-to-read-the-alerts-page/) flags any day whose spend jumps above your organization's recent normal. A 20-repository bulk scan is a sudden jump on one day, which is exactly what it catches. If spend spikes with no matching jump in AI credits, a new paid line, like a security SKU, is the usual cause. Check the SKU table before you check your developers.

**3. Watch included Copilot credits on the Copilot page.** The [Copilot page](/blog/how-to-read-the-copilot-page/) and the [Developers page](/blog/how-to-read-the-developers-page/) show who on your team is actually using credits. If the allowance runs out earlier in the month but developer usage looks normal, the gap came from somewhere else. Now you know where to look.

**4. Back GitHub's hard budget with an org-wide warning.** Set the Code Security hard budget in GitHub, because only GitHub can stop a scan. Then, on the [Budgets page](/blog/how-to-read-the-budgets-page/), an org-level dollar budget warns at 80% and 100% of total GitHub spend, including security AI. The GitHub-configured budgets card shows GitHub's own budgets in the same view.

> **Honest limits:** we haven't yet seen the Code Security AI credits SKU in a live tenant, so we can't confirm the exact product and SKU names GitHub reports. When AI Scan uses up included Copilot credits, the billing API doesn't say which credits went to scans and which to developers, so FinOpsAid can't split that pool. Product-level budgets in FinOpsAid cover Copilot, Actions and storage, not Advanced Security. And GitHub's billing data lags two to three days, so FinOpsAid helps you investigate after a scan runs; it can't stop one.

## What to do before bulk start

1. **Decide at enterprise level whether AI Scan is allowed.** It defaults to "Not allowed", so this is an active choice.
2. **Set a hard SKU budget for Code Security AI credits in GitHub,** then enable the settings.
3. **Turn on PR scanning only where those languages actually live.** Terraform, Shell, PHP and Dockerfile-heavy repositories are where it adds coverage. Each commit to those pull requests is a scan.
4. **Agree who may bulk-start repository scans.** Twenty repositories is one click, and the docs set no frequency limit.
5. **Connect FinOpsAid before the first scan,** so you have a normal baseline to compare against when the security line appears.

Related: [budgets that catch overspend early](/blog/github-budgets-that-catch-overspend-early/), [what actually consumes GitHub AI credits](/blog/what-actually-consumes-github-ai-credits/), and [cost centers and AI credit pools](/blog/github-cost-centers-and-ai-credit-pools/).

## Frequently asked questions

### Does GitHub AI Scan need a Copilot license?

No. AI Scan for pull requests and AI Scan for repositories don't require a GitHub Copilot license. They do consume Code Security AI credits. Private and internal organization repositories also need GitHub Code Security or GitHub Advanced Security.

### Does AI Scan use my Copilot AI credits?

It uses included AI credits from a Copilot entitlement first, if your account has them. Once those run out, or if there are none, usage is metered as Code Security AI credits under your budgets. It appears under Advanced Security in the AI usage section of billing.

### How can I see AI Scan spend next to Copilot spend?

GitHub reports AI Scan under Advanced Security and Copilot separately. FinOpsAid stores every product and SKU line from GitHub's billing usage API. It shows them together on Cost Explorer by day, and flags sudden jumps on the Alerts page, so you can see a security scan's cost on the same chart as your Copilot spend.

### How much does a GitHub AI Scan cost?

GitHub doesn't publish a per-scan price. For repository scans, detection is capped at 30 minutes and 150,000 AI credits, which is $1,500 at $0.01 per credit. That's a ceiling, not a typical cost. Pull request scans run on every new commit, so their cost scales with push activity.

## Sources

- GitHub Docs, "AI Scan for a repository's backlog", retrieved 2026-11-17, https://docs.github.com/en/code-security/concepts/code-scanning/ai-scan-for-repositories
- GitHub Docs, "AI Scan for pull requests", retrieved 2026-11-17, https://docs.github.com/en/code-security/concepts/code-scanning/ai-powered-security-detections
- GitHub Docs, "GitHub Advanced Security license billing", retrieved 2026-11-17, https://docs.github.com/en/billing/concepts/product-billing/github-advanced-security
- GitHub, "AI Scan for pull requests generally available", retrieved 2026-11-17, https://github.blog/changelog/2026-10-15-ai-scan-for-pull-requests-generally-available/
- GitHub, "AI Scan for repositories in public preview", retrieved 2026-11-17, https://github.blog/changelog/2026-10-28-ai-scan-for-repositories-in-public-preview/
- GitHub, "Manage AI Scan for repositories using the REST API", retrieved 2026-11-17, https://github.blog/changelog/2026-11-13-manage-ai-scan-for-repositories-using-the-rest-api
- GitHub, "Bulk start AI Scan for repositories", retrieved 2026-11-17, https://github.blog/changelog/2026-11-16-bulk-start-ai-scan-for-repositories

*Find out what your security scans cost before someone blames the developers. [Connect your GitHub org](/setup/) in a few minutes. It's read-only and free during beta. You'll see every billing product and SKU by day, with alerts on sudden jumps. Or [explore the demo dashboard](/overview) first.*
