Cloudflare Pages deployment decision map comparing Git integration and Direct Upload from source of truth through preview and production

Cloudflare Pages Git Integration vs Direct Upload

Choose Cloudflare Pages Git integration when GitHub or GitLab is the source of truth and every approved branch change should create a managed build and preview. Choose Direct Upload when the deployable artifact is built locally or by another CI system and you want to publish prebuilt files with Wrangler or dashboard upload. Make this choice before project creation because Cloudflare treats the deployment mode as a project-level decision.

Intent and ownership

This comparison owns deployment choice, not every Cloudflare Pages task

This article owns one informational decision: choose and verify the deployment operating model for one Cloudflare Pages project before launch. It compares Git integration, Direct Upload with Wrangler, and dashboard drag and drop. It also covers preview behavior, custom-domain readiness, public route checks, rollback evidence, and the minimum handoff that makes the choice maintainable.

It does not own commercial searches for a developer or launch service. The Cloudflare Pages landing page service remains the fixed-scope commercial owner for one responsive service page, deployment setup, metadata, mobile QA, live URL checks, and handoff notes. The Technical SEO and Cloudflare launch checklist remains the broad launch-hygiene guide. The Cloudflare DNS and SSL audit remains the focused diagnosis route for an existing domain, SSL, redirect, header, or zone problem.

Cloudflare product behavior, plan limits, dashboard labels, build images, CLI commands, and supported providers can change. Recheck the current official documentation and the actual account before production work. This is implementation guidance, not Cloudflare support, a platform affiliation, security certification, legal advice, or a guarantee of availability, indexation, ranking, or performance.

User task Canonical route Owned outcome Not owned
Choose Git integration or Direct Upload This article Deployment-mode decision, release evidence, and handoff checklist Done-for-you page design or an account-level DNS diagnosis
Launch one fixed-scope service landing page Cloudflare Pages launch service Bounded implementation under the published scope Open-ended site development or undefined application work
Audit DNS, SSL, redirects, or headers Cloudflare DNS and SSL audit Focused current-state diagnosis and evidence Building a new landing page
Prepare metadata and schema for existing service pages Technical SEO and schema pack Page-level metadata and structured-data implementation Hosting migration or Cloudflare account repair

Decision matrix

Start with the source of truth and release owner

A deployment method is not only an upload button. It decides where the release begins, which system builds the final artifact, how a reviewer sees a preview, what evidence connects a code change to production, and who can repeat the process after the original builder leaves. The best method is the one that makes those responsibilities explicit with the least hidden manual work.

Decision factor Git integration Direct Upload with Wrangler Dashboard drag and drop
Source of truth Connected GitHub or GitLab repository and approved branches Local or CI-generated build output plus the deployment command The exact prebuilt folder or archive selected by the operator
Production trigger Push or merge under branch controls, unless automatic deployments are disabled Explicit Wrangler deployment from an accountable environment Explicit upload and confirmation in the dashboard
Preview model Branch and pull-request previews are part of the repository workflow Wrangler can create preview deployments with an explicit branch A preview environment can be selected during upload
Build ownership Cloudflare Pages build configuration and repository state Your local or external CI build, then Cloudflare receives prebuilt assets Your local build, then a human selects the final assets
Pages Functions Supported through the repository build and project configuration Wrangler can upload a functions folder when deployed from the correct directory Dashboard drag and drop does not compile a functions folder; check current `_worker.js` support separately
Provider fit Native GitHub or GitLab repository connection Custom CI, a different Git provider, self-hosted source, or local build Small static release with a clear human-controlled artifact
Repeatability risk Hidden branch, build, environment, or repository-access settings Unrecorded command, token scope, output directory, or CI artifact Wrong folder, stale build, missing files, or no durable release command
Mode change Cannot convert to Direct Upload mode; automatic builds can be disabled and Wrangler can deploy manually Cannot convert to Git integration; a new project is required for that mode Part of Direct Upload; the same project can use Wrangler later
  1. 01Name the source of truth
  2. 02Choose Git or upload
  3. 03Prove a preview
  4. 04Attach the domain
  5. 05Test public routes
  6. 06Prove rollback and handoff
Crawlable equivalent of the deployment-choice visual: source of truth, project mode, preview, custom domain, public route validation, and recovery evidence must form one accountable release path.

Stage 1: deployment contract

Write the operating model before creating the project

Record the project owner, Cloudflare account, intended project name, repository or build-source location, production branch or artifact, build command, output directory, environment variables, secret owner, custom domain, canonical host, preview policy, production trigger, rollback owner, and handoff destination. If any of those are unknown, the project is not ready for an irreversible mode choice.

Separate source from output. In a Git-integrated project, the repository is the durable source and Cloudflare runs the configured build. In Direct Upload, the deployable directory is already built; the team must preserve how that directory was produced. Uploading `dist` is not a handoff if nobody can reproduce `dist` from the actual source six weeks later.

Define the smallest production acceptance set. For a service landing page, that usually includes the intended hostname, HTTPS, title, description, H1, canonical, robots behavior, social image, mobile layout, primary CTA, form or contact route, 404 behavior, redirects, headers, sitemap or discovery path, analytics when in scope, and one rollback target. Add application-specific checks only when the project actually uses them.

Stage 2: Git integration

Choose Git integration when the repository should control the release

Cloudflare Pages can connect a project to GitHub or GitLab and automatically build on branch changes. That model is strongest when reviewed commits already represent approved changes, the build is reproducible in Cloudflare's environment, and branch or pull-request previews are part of normal QA. The repository provides an audit trail, but only if the production branch, build settings, environment variables, and access permissions are documented too.

Verify the build command, output directory, and root directory with the real framework or static source. A successful command exit is not enough if the wrong directory is uploaded, required environment variables are absent, or the build silently writes an incomplete site. Pin important runtime or build-tool versions instead of depending indefinitely on an unrecorded default build image.

Use branch controls deliberately. Decide which branch can deploy to production, whether preview branches are automatic, and whether untrusted contributions can reach a public preview. Cloudflare's Git integration creates preview URLs and repository status checks, but the team must still define who approves the preview and what evidence permits merge or release.

If automatic deployments later become undesirable, do not describe the project as converted to Direct Upload. Cloudflare documents a different path: disable automatic production and preview branch deployments, then use Wrangler to deploy manually to the existing Git-integrated project. Preserve that distinction in the handoff so a later operator does not create a second project unnecessarily.

Stage 3: Direct Upload

Choose Direct Upload when another process owns the build artifact

Direct Upload fits a project whose final static assets are built locally, by a custom CI pipeline, or from a provider that Cloudflare Pages does not connect to natively. The release contract must name both the source and the artifact because Cloudflare receives the output, not the complete reasoning that produced it.

Prefer Wrangler for a repeatable operational path. Preserve the exact build command, working directory, output directory, project name, branch or environment choice, CLI version policy, token scope, and non-secret command template. Keep secrets in the approved environment rather than shell history, source control, screenshots, or a public handoff document.

Dashboard drag and drop can be suitable for a small static bundle, but validate its current limits before selecting it. Cloudflare's current Direct Upload documentation lists a lower file-count limit for drag and drop than Wrangler. It also states that dashboard drag-and-drop deployments do not compile a `functions` folder, while Wrangler can upload that folder when run from the correct location. Do not discover that boundary after the custom domain has been moved.

A Direct Upload project can alternate between Wrangler and dashboard drag and drop, but it cannot later become Git-integrated. If repository-driven automatic builds are a likely near-term requirement, resolve that operating-model decision before launch or explicitly accept the cost of a future new-project migration.

Stage 4: preview and release

Use a preview as evidence, not as the production decision

A preview should answer whether the exact proposed release behaves correctly without changing the production hostname. Verify the generated deployment URL, commit or artifact identity, build result, responsive layout, navigation, assets, forms, console behavior, headers, robots directives, and any environment-specific configuration. Keep a compact record of the preview and the person who approved it.

Cloudflare currently adds an `X-Robots-Tag: noindex` response header to preview deployments by default. Confirm that header rather than assuming a random deployment URL is invisible. Preview URLs can still be public unless access controls are enabled, so do not put private customer data, live secrets, confidential drafts, or unsafe test endpoints into a preview simply because it is not intended for search.

Define production separately. For Git integration, record the production branch and approval event. For Direct Upload, record the exact production command or dashboard action and artifact checksum or version. After release, fetch the custom domain and the production `pages.dev` route as intended, then compare the result with the approved preview before announcing completion.

Stage 5: custom domain

Attach the hostname through the Pages project before editing DNS blindly

Add the intended hostname through the Pages project's Custom domains workflow. Cloudflare documents different requirements for apex domains and subdomains: an apex domain must be a zone in the same Cloudflare account with nameservers configured appropriately, while an external-DNS subdomain can use a CNAME to the project hostname. The dashboard association still matters; Cloudflare warns that manually pointing a CNAME without first associating the domain in Pages can produce a 522 response.

Decide the canonical public hostname before launch. Test HTTPS, certificate state, apex and `www` behavior, trailing slash policy, query preservation, old-host redirects, and representative deep paths. If the generated `pages.dev` production hostname should not remain an alternate public copy, use the current supported redirect or access approach and verify it from an external request.

Keep DNS rollback evidence. Record the previous relevant records, TTL context, the new Pages association, certificate or CAA constraints, expected propagation, and the exact condition that triggers rollback. Avoid broad DNS changes when only one subdomain is required.

Stage 6: public web contract

Validate redirects, headers, routes, and search signals on the final host

Test the homepage, one deep page, the primary conversion path, declared assets, `robots.txt`, sitemap or discovery route when present, favicon, social image, and a genuine missing URL. Cloudflare Pages supports a custom `404.html`; verify the status and content behavior that the project actually needs instead of accepting a styled error page that returns the wrong status.

Keep `_redirects` and `_headers` inside the reproducible build output. Cloudflare applies redirects before headers, so a request matching both will follow redirect behavior first. Cloudflare also notes that `_headers` rules do not apply to responses generated by Pages Functions; those headers need to be set in function code. Test headers on both static and function-generated routes when the project uses both.

For search readiness, verify one intended indexable production host, self-referencing canonicals on indexable pages, no accidental production `noindex`, consistent titles and H1s, accessible content without client-side failure, descriptive internal links, and no preview or old-host duplication. Request search-engine discovery only after the live release is stable; an indexing request does not repair a deployment or guarantee inclusion.

Stages 7 and 8: recovery and handoff

Prove that another operator can release and recover the project

Cloudflare Pages supports rollback to a previous successful production deployment. Preview deployments are not rollback targets. Before launch, identify at least one valid prior production deployment when one exists, name the rollback owner, and define what evidence justifies a rollback. For a first release with no useful previous production version, keep the prior DNS route or other approved recovery plan explicitly instead of claiming that platform rollback solves every failure.

The handoff should let an authorized operator reproduce the build, create a preview, approve production, verify the custom domain, observe the release, and roll back without depending on private memory. Include repository or source location, build command, pinned versions, output path, deployment mode, project and account identifiers, branch controls, environment-variable names without secret values, domain records, redirects, headers, QA evidence, rollback steps, and named owners.

Browser-local worksheet

Complete 32 checks before approving the deployment mode and launch

This worksheet stores completion in this browser only. It does not send credentials, files, domains, or customer data to eArif.com. Checked boxes are planning evidence, not proof that the live system passed; retain the actual URLs, headers, screenshots, logs, commit or artifact identity, and accountable approval in the private project record.

0 of 32 checks complete

0 of 32

Hold: the review is incomplete.

01Ownership and source
02Deployment-mode decision
03Build and configuration
04Preview acceptance
05Domain and HTTPS
06Public web and search
07Production and observation
08Recovery and handoff

Implementation route

Choose the route that matches the first unresolved layer

Current evidence Best next route Why
One service landing page is ready for a bounded build and launch Cloudflare Pages landing page service The `$497` Starter scope owns one responsive page, deployment setup, metadata, mobile QA, live URL checks, and handoff notes under the published boundaries.
The page exists but DNS, SSL, redirects, or headers are uncertain Cloudflare DNS and SSL audit The first need is current-state diagnosis rather than a new deployment.
Existing service pages need metadata and schema work Technical SEO and schema pack The issue is page-level search presentation and structured data, not hosting mode.
The release crosses application code, CRM, forms, analytics, or several accountable systems Systems Audit The first failed handoff and source of truth must be diagnosed across tools.
The mode, scope, or safe access path is still unclear Contact Arif with privacy-safe context Share the platform, source type, intended domain, page count, deployment state, deadline, and redacted error text without credentials or private customer data.

Review Cloudflare and Technical SEO Services for the category view, Proof before treating public guidance as project evidence, Privacy before sharing account details, Learning Cave for adjacent guides, and the AI Search Profile when a search or research agent needs the correct source for Arif's role and service boundaries.

Primary sources reviewed July 31, 2026

Official Cloudflare documentation used for this comparison

Deployment behavior, limits, dashboard steps, supported providers, build images, and CLI syntax can change. Recheck the current official pages and the actual project before production work.

  1. Cloudflare Pages: Git integration for supported providers, automatic branch deployment behavior, preview features, mode-switching limits, branch controls, and manual Wrangler deployment from a Git-integrated project.
  2. Cloudflare Pages: Direct Upload for prebuilt assets, Wrangler, drag and drop, project-mode limits, upload limits, production-branch behavior, and Pages Functions boundaries.
  3. Cloudflare Pages: Build configuration for build commands, root and output directories, exit behavior, framework presets, and injected environment variables.
  4. Cloudflare Pages: Preview deployments for branch previews, aliases, access control, public-preview behavior, and default `X-Robots-Tag: noindex` responses.
  5. Cloudflare Pages: Custom domains for dashboard association, apex-zone requirements, subdomain CNAME setup, certificate constraints, and the warning against a manual CNAME without project association.
  6. Cloudflare Pages: Redirecting `pages.dev` to a custom domain for the supported Bulk Redirect approach and path/query preservation options.
  7. Cloudflare Pages: Rollbacks for valid production rollback targets and the preview-deployment limitation.
  8. Cloudflare Pages: Limits for current build, project, file, file-size, custom-domain, preview, redirect, and header limits.
  9. Cloudflare Pages: Headers for `_headers` placement, static-response behavior, function-response boundaries, matching, and redirect precedence.
  10. Cloudflare Pages: Redirects for `_redirects` syntax, static and dynamic routing, ordering, and proxy behavior.
  11. Cloudflare Pages: Serving Pages for custom 404 behavior, static asset caching, and route-serving expectations.

Frequently asked questions

Cloudflare Pages deployment-choice questions

Can a Cloudflare Pages Direct Upload project switch to Git integration?

No. Cloudflare's current Direct Upload documentation says a Direct Upload project cannot switch to Git integration. A new project is required to use the Git-integrated automatic deployment model. Plan the new project, preview, custom-domain reassignment, canonical host, and rollback path before moving production.

Can a Git-integrated Cloudflare Pages project deploy with Wrangler?

Yes, without converting the project to Direct Upload mode. Cloudflare documents that a Git-integrated project can disable automatic production and preview branch deployments and then use Wrangler for manual deployments. Record that hybrid operating model clearly so future operators do not confuse it with a Direct Upload project.

Is dashboard drag and drop the same as Wrangler Direct Upload?

Both are Direct Upload methods, but their operational behavior and current limits differ. Cloudflare currently lists a lower file-count limit for drag and drop, and dashboard drag and drop does not compile a Pages Functions folder. Wrangler is usually the stronger choice when the release must be repeatable, scripted, or include that functions workflow.

Will Cloudflare Pages preview URLs be indexed?

Cloudflare currently sends `X-Robots-Tag: noindex` on preview deployments by default. Verify the response header on the actual preview. A noindex directive is not an access control: previews can still be public unless an access policy protects them, so never place private data or secrets there.

Do I add the custom-domain CNAME before adding the domain in Pages?

Use the Pages project's Custom domains workflow first. Cloudflare warns that manually pointing a CNAME at a Pages hostname without first associating the domain in the Pages dashboard can produce a 522 response. Apex and external-DNS subdomain requirements differ, so verify the current official process for the intended hostname.

Does a successful Cloudflare Pages deployment mean the site is ready for search?

No. A successful deployment only proves that Cloudflare accepted and served an artifact. Search readiness still requires the intended production host, HTTPS, correct status codes, accessible content, titles, H1s, canonicals, robots behavior, internal discovery, mobile QA, conversion paths, and no conflicting preview or old-host copy. Search engines control crawling, indexing, and ranking.

Back to blog