# Cloudflare optimization

Cloudflare optimization is nimo's edge fix path. When your site runs behind Cloudflare, nimo can suggest changes and apply approved changes from chat.

Canonical URL: https://heynimo.com/docs/cloudflare-optimization
Markdown URL: https://heynimo.com/docs/cloudflare-optimization.md

## AI summary

Explains Cloudflare OAuth, the three-audit learning phase, supported edge optimizations, approval before chat-applied changes, verification after apply, rollback, and change history.

## Key points

- Connect Cloudflare with OAuth.
- nimo waits for a three-audit baseline before suggestions.
- Supported fixes include image optimization, Brotli, Early Hints, Auto Minify, and Browser Cache TTL.
- Every change requires approval before nimo applies it through chat; applied changes can be verified and rolled back through chat.

## Sections

### Connect Cloudflare

- Open Settings, go to Integrations, and choose Cloudflare.
- Sign in with Cloudflare and allow account read, analytics read, zone read, zone settings read/edit, and cache purge.
- nimo needs enough audit history before it suggests infrastructure changes.

### Learning phase

- nimo waits for a three-audit baseline before suggesting Cloudflare changes.
- The learning phase helps nimo avoid changing settings because of one noisy run.

### Supported fixes

- Image Polish and WebP can improve image delivery at the edge when images are a real bottleneck.
- Brotli compression can compress text assets so pages transfer less data.
- Early Hints can let browsers begin loading important resources sooner.
- Auto Minify can minify HTML, CSS, or JavaScript when it is safe for the site.
- Browser Cache TTL can improve repeat visits by caching static assets longer.

### Approve and verify

- nimo does not apply a Cloudflare change without approval.
- Approval records your intent. To make the change, ask nimo in chat to apply the approved action.
- nimo changes the Cloudflare setting through MCP and records the previous value.
- Once the change is applied, nimo can queue a verification audit and log the before-after result when data exists.

### Roll back a change

- Applied optimizations store the previous setting.
- If a change causes trouble or does not help, ask nimo in chat to roll it back and record the rollback.


## Related docs

- [Quick start](https://heynimo.com/docs) - Add a site, connect Telegram, and ask nimo what to fix first.
- [Set up a site](https://heynimo.com/docs/setup) - Add your site, pick a schedule, and understand what nimo checks.
- [Telegram](https://heynimo.com/docs/telegram) - Connect Telegram and use nimo from chat.
- [MCP for agents](https://heynimo.com/docs/mcp) - Use public docs MCP, or connect an authenticated MCP client to nimo.
- [Audits](https://heynimo.com/docs/audits) - Run audits and read Core Web Vitals without the jargon.
