# Build and publish a landing page with Gemini CLI

> Configure Gemini CLI's HTTP MCP connection, check browser OAuth, build a single-page offer, and verify the live form. Includes a complete project prompt.

- Canonical: https://pageree.com/guides/gemini-cli-landing-page/
- Published: 2026-09-15. Updated: 2026-09-15.
- Collection: Guides (https://pageree.com/guides.md)
- Site index for agents: https://pageree.com/llms.txt

**The short answer.** Gemini CLI uses its own settings and HTTP transport field; consumer Gemini app access is separate. Verify the remote connection and local browser sign-in first, then build, preview, publish, and check the final enquiry destination in your account.

## Use Gemini CLI for a file-based landing page

Gemini CLI runs in your terminal and can work with project files and connected tools. This guide concerns that CLI, not the consumer Gemini app. The product name alone does not establish that another Gemini surface has the same configuration or publishing access.

The instructions follow current Gemini CLI MCP documentation, reviewed on September 15, 2026. A live Gemini-account-to-Pageree publication was not performed for this guide. Start by checking your installed version, browser sign-in availability, and organization permissions; then verify a read-only account call before building.

## Configure Streamable HTTP correctly

Gemini CLI uses an `mcpServers` object in its settings. Merge this into the appropriate existing `settings.json` configuration for your CLI:

```json
{
  "mcpServers": {
    "pageree": {
      "httpUrl": "https://mcp.pageree.com/"
    }
  }
}
```

The `httpUrl` field selects HTTP streaming. Gemini CLI's documentation distinguishes it from `url`, which is used for SSE. The CLI also documents OAuth discovery and browser authentication for remote servers. See [Gemini CLI's MCP guide](https://geminicli.com/docs/tools/mcp-server/).

Start or restart the CLI, inspect `/mcp`, and complete the authentication flow for Pageree. Browser callbacks must reach the machine running the CLI. A remote shell or container can complicate that flow even when the server itself is reachable. Use the official troubleshooting guidance rather than disabling authentication or pasting credentials into project files.

Ask Gemini to read the account and list its pages. If this fails, note the actual authentication or discovery error. Keep content drafting separate from publication until the tools work. The [Pageree docs](https://pageree.com/docs/) provide the current endpoint and supported workflow.

## Give the terminal agent an explicit output contract

A CLI can generate many kinds of projects. Tell it which kind you need. For an illustrative campaign, use a small-business offer for organizing a shared document library:

```text
Create a landing page for my document-organization service.
Audience: owners of small teams struggling to find current business documents.
Offer: review one shared folder and propose a clear structure and naming approach.
Goal: request a conversation about the project.
Read the supplied brief. Ask for missing facts, scope, price, and genuine evidence.
Do not imply you will access visitors' files through the landing page.
Use Pageree's current page, form, privacy, asset, and publishing skills.
Build one HTML document with inline CSS and JavaScript and hosted image URLs.
The enquiry form should collect name, email, team size, and the main problem.
Ask me to choose the page slug and destination inbox.
Save a private preview, store the page ID locally, and wait for my review.
```

This scope makes the promise credible: the form starts a service conversation. It does not pretend to inspect a visitor's drive or deliver a custom result immediately. Use the [brief worksheet](https://pageree.com/guides/landing-page-brief-template/) when the deliverables are still unclear.

## Inspect files and preview separately

Check whether the generated HTML refers to local images, a separate stylesheet, or a package that requires a build server. Those may work in a project preview but need adaptation for Pageree's single-document hosting contract. Keep secrets and internal documents out of the page source.

Open the private preview in a browser. If your CLI session has no browser-inspection tool, review it yourself rather than asking the model to infer appearance from HTML. Check narrow screens, readable text, focus states, labelled inputs, and the visitor's next step after submission.

Save revisions with the same page ID. The live page, if one exists, keeps serving its current version while you refine a draft. Review the [preview guide](https://pageree.com/guides/preview-landing-page-before-publishing/) for checks that cannot be established by a source file alone.

## Publish and verify the business outcome

Approve the reviewed preview, then have Gemini publish it and return the public URL. Open that URL independently. Submit a clearly marked enquiry using an inbox you control and confirm the destination receives it. A successful draft email test does not establish that a live HTTP integration works.

Start with the [email-delivery workflow](https://pageree.com/guides/landing-page-form-to-email/) if you do not yet need a CRM. Once the page and form work, connect your owned hostname using the actual returned DNS instructions in the [custom-domain guide](https://pageree.com/guides/ai-landing-page-custom-domain/).

Keep the brief and page identity in the project. Future CLI sessions should retrieve the current stored HTML before changing the offer, so a resumed conversation does not replace newer work with an older local draft.

## Related
- [Build and publish a landing page with OpenCode](https://pageree.com/guides/opencode-landing-page.md): Connect OpenCode v2 to Pageree using the current MCP structure. Build static HTML, review the preview, publish, and retain the page ID for future updates.
- [Build and publish a landing page with Codex](https://pageree.com/guides/codex-landing-page.md): Use Codex CLI with Pageree's remote MCP connection. Configure OAuth, prepare a focused page, review the output, and verify the published enquiry destination.
- [Host an HTML landing page with a working enquiry form](https://pageree.com/guides/host-html-landing-page.md): Compare static hosting, separate form services, and Pageree for an HTML landing page. Check dependencies, adapt assets, and verify the full enquiry path.

## Build it with your agent

Pageree is an MCP server. Add https://mcp.pageree.com/ to an MCP client that supports Streamable HTTP and OAuth, sign in, and the agent can build, publish and measure the page. Setup for every supported client: https://pageree.com/docs.md. Sign up: https://console.pageree.com/signup.
