Home / Blog / Build a fast website with AI
Guide · Speed

How to build a fast website with AI (and what actually slows sites down)

Short answer: A fast website shows its main content within 2.5 seconds on a phone. Most small-business sites don't. In PageSpeed tests we ran on small-business websites in 2026, the median site needed 7.1 seconds for its largest element, and 9 in 10 missed Google's 2.5-second mark. JavaScript was rarely the problem. The time went into the first big image and everything loaded before it: tag managers, cookie tools, page builders and sliders. When AI builds the site, give it those rules up front. A copy-paste block for Claude is below.

"Which is the fastest CMS?" is the question most people start with. It's the wrong first question. A content management system decides how pages are stored and served, but the things that made the sites in our data slow can be added in any CMS, and just as easily by an AI that wasn't told to leave them out.

That matters more every month, because more sites are now written by AI tools. Among new German companies in 2026, 2.5% of websites carried a clear AI-builder fingerprint and up to 15% were modern code in the style AI tools write (our study of 1,536 new companies, more in how many small-business sites are built with AI). Among established small businesses it is rarer still: of 2,538 websites in 16 cities in Germany, Austria and Switzerland, 0.4% were made with an AI site builder and at most 3.1% look AI-written. An AI builds exactly as fast a site as its brief asks for.

Key takeaways

  • The bar: Largest Contentful Paint (LCP) of 2.5 seconds or less for at least 75% of visits. Above 4 seconds is poor.
  • The typical small-business site misses it: median LCP 7.1 seconds and a median mobile PageSpeed score of 64 in our 2026 sample.
  • It's not the JavaScript: median Total Blocking Time was only 17 milliseconds. The delay is the first big element and what loads before it.
  • The usual suspects were slower: sites with a tag manager or tracking pixel had a median LCP of 11.0 seconds, against 6.4 seconds without.
  • With AI, speed is a brief: put a budget and a handful of rules in the prompt or in CLAUDE.md, then check the result in PageSpeed Insights.

What "fast" means: the numbers Google uses

Google measures speed with three Core Web Vitals. The targets below come from web.dev, Google's own documentation, and apply to the 75th percentile of page loads, split by mobile and desktop.

MetricWhat it measuresGood
Largest Contentful Paint (LCP)When the biggest element on the first screen, usually the hero image or headline, has appeared2.5 s or less (above 4.0 s is poor)
Interaction to Next Paint (INP)How quickly the page reacts to a tap or click200 ms or less
Cumulative Layout Shift (CLS)How much the layout jumps while it loads0.1 or less

The PageSpeed score from 0 to 100 is a separate thing: a Lighthouse lab test. Google rates 90 to 100 as good, 50 to 89 as needs improvement and 0 to 49 as poor. For the mobile test, PageSpeed Insights simulates a mid-tier phone on a mobile network, which is why a site that feels quick on your office desktop can score badly.

What we measured on small-business websites

Before we rebuild a site, we test its homepage with Google PageSpeed Insights, mobile lab test, the same check our free website analyzer runs. The figures below come from more than 130 small-business websites we tested this way in 2026, one measurement per site, mostly WordPress (ShiftPress data, 2026).

Measure (mobile)Result
Median PageSpeed performance score64 / 100
Sites scoring 90 or more ("good")19%
Sites scoring below 50 ("poor")16%
Median Largest Contentful Paint7.1 s
LCP slower than 2.5 s90%
LCP slower than 4.0 s ("poor")71%
Median Total Blocking Time17 ms
Layout shift above 0.116%

The striking number is the last but one. Total Blocking Time measures how long JavaScript keeps the browser busy. At a median of 17 milliseconds it was close to zero, so the typical site wasn't slow because of heavy code running. It was slow because the biggest thing on the first screen took seven seconds to arrive. That points at image size and at everything the browser has to fetch before it gets to that image.

What the slow sites had in common

When our copier reads a site, it notes what's on it: a tag manager, a cookie tool, a page builder, a slider. Put next to the PageSpeed results, a pattern shows up.

On the siteMedian LCP with itMedian LCP without itMedian score with / without
Tag manager or tracking pixel11.0 s6.4 s57 / 66
Slider or carousel8.8 s7.1 s64 / 64
Cookie consent tool8.7 s6.3 s61 / 65
Page builder (Elementor, Divi, WPBakery)7.8 s6.7 s63 / 66

Read this as a pattern, not as proof. These things often travel together (a site with a tag manager usually has a cookie tool too), and some groups are small. But the direction is the same in every row, and it matches Google's own LCP guidance: anything that delays the browser from finding and loading the main image makes the page slower.

Weight tells the same story. In our website carbon report, the median homepage of a new company weighed 1.62 MB. A phone on a mobile network needs time for every one of those megabytes.

How fast is your site on a phone?

Our free check runs the same mobile PageSpeed test and shows your LCP, your score and what holds the page back. No login.

Check my site ↗

The checklist, ordered by what moved the numbers

1. Make the first screen light

One hero image, not a slider. Export it at the size it's shown (about 1,600 pixels wide is plenty for a full-width hero), as WebP or AVIF, and compress it. Give the <img> a width and height so nothing jumps, add fetchpriority="high", and never lazy-load it: Google's guidance says lazy-loading the LCP image "will always lead to unnecessary resource load delay". If the hero is a headline on a colour, even better: text is the fastest LCP element there is.

2. Cut third-party scripts, starting with the tag manager

In our data this was the biggest gap: 11.0 against 6.4 seconds. A tag manager is a container that loads more scripts, so it tends to grow. Ask which tools you actually look at. One analytics script, loaded after consent, is enough for most small businesses. Maps, video and social feeds below the fold can show a static preview and load on click.

3. Choose the consent tool with the page in mind

A banner that loads its own framework, fonts and a vendor list before anything else costs time on every visit. Fewer trackers means a smaller banner, and a site that sets no tracking cookies at all needs far less consent machinery. Whether you need a banner is a legal question for your own case, but the speed effect is not.

4. Skip the page builder

Visual page builders wrap every section in layers of extra markup, CSS and scripts. The gap in our data was smaller than for scripts (7.8 against 6.7 seconds), but it's there on every page. When AI writes the site, there is no reason for a builder: plain HTML and CSS is what Claude writes best anyway.

5. Keep fonts to two files

Self-host the fonts (no request to a font service), use woff2, two weights at most, and font-display: swap so text shows immediately in a fallback font.

6. Serve static files from a CDN

A static page is built once and then served as a finished file from servers near the visitor, so the first byte arrives quickly. That's the part where the choice of system really matters, and it's why static sites are a good fit for small businesses (more in static website SEO).

7. Everything below the fold: lazy, sized, light

Images further down get loading="lazy", a width and height, and a srcset so phones don't download desktop sizes. That keeps layout shift low and the first screen free.

Tell Claude: the rules in one block

Claude follows a performance brief well. Without one, it often reaches for big stock images, several font weights and a library or two. Paste this into your first prompt, or into CLAUDE.md if you build in Claude Code, so it applies to every page:

## Performance rules (apply to every page)
    - Budget: LCP under 2.5 s on a mid-range phone, CLS under 0.1,
      homepage under 1 MB in total.
    - Hero: one image or plain text on colour. No slider, no carousel,
      no autoplay video.
    - Hero image: max 1600 px wide, WebP or AVIF, compressed, width and
      height set, fetchpriority="high", never loading="lazy".
    - All other images: loading="lazy", width and height set, srcset
      with a phone and a desktop size.
    - Fonts: self-hosted woff2, max 2 files, font-display: swap.
    - Plain HTML and CSS. No page builder, no UI framework for content
      pages, JavaScript only where a feature needs it.
    - No tag manager. One analytics script, loaded only after consent.
    - Maps, videos and social feeds: static preview, load on click.
    - When done, list each page's total weight and its LCP element.

Design skills make the result look better without breaking these rules; our list of the best Claude skills for web design covers which ones to load, and which Claude model to use covers the model. After each build, run the homepage through PageSpeed Insights on mobile and paste the top findings back to Claude.

So which CMS is fastest?

For a small business, the fastest setup is the one that serves finished static pages and stays out of the way. If you already have a content library, choose a system that can import it without a rebuild, publishes static pages or caches every page completely, and doesn't force a page builder on you. Then test one real page before moving the rest. Our comparison of CMS platforms goes through the options. Just keep the numbers above in mind: none of the slow sites in our sample were slow because of the CMS name in the footer. They were slow because of what was put on the first screen. The quickest version of all this is to let ShiftPress build the first draft and spend your time on the facts only you know.

Already built your site with Claude?

Upload it to ShiftPress as a ZIP: a Claude Design export or plain .html pages, up to 30 per file. Every page becomes a real page you can edit, and from then on you change it by describing what you want instead of re-uploading files. Free to start, no credit card. Your own domain comes with a paid plan.

Upload my Claude site ↗

Frequently asked questions

What is the fastest CMS for a website?
For a small site, the fastest setup is one that serves finished static HTML from a CDN, so no server has to build the page on each visit. But the CMS is rarely what makes a site slow. In our measurements the time went into the first big image and the third-party scripts loaded before it, and every CMS lets you add those.
How do I choose a fast CMS that fits an existing content library?
Pick one that either publishes static pages or caches every page completely, keeps the theme free of page-builder markup, and lets you import your existing pages without rebuilding them by hand. Then test a real page with PageSpeed Insights on mobile before you move everything.
How fast should a website load?
Google's target is a Largest Contentful Paint of 2.5 seconds or less for at least 75% of visits. Above 4 seconds counts as poor. Layout shift (CLS) should stay at 0.1 or less and responsiveness (INP) at 200 milliseconds or less.
What is a good PageSpeed score?
90 to 100 is good, 50 to 89 needs improvement and 0 to 49 is poor. In our 2026 sample of small-business sites, the median mobile score was 64 and only about one site in five reached 90.
Why is my website slow on mobile?
Usually because of the first big image and what loads before it. PageSpeed tests mobile on a simulated mid-tier phone and a slow mobile network, so a 2 MB hero photo, a slider, a tag manager or a heavy cookie tool shows up far more than on your office desktop.
Can AI build a fast website?
Yes, if you tell it the rules. Claude writes lean HTML and CSS when asked, but without rules it often reaches for big images, several web fonts and libraries. Give it a performance budget and concrete rules in the brief or in CLAUDE.md, then check the result with PageSpeed Insights.
Does a cookie banner slow down a website?
It can. In our sample, sites with a cookie consent tool had a median LCP of 8.7 seconds, against 6.3 seconds without one. Much of that comes from the tracking the banner exists for, so the fastest fix is often to load fewer trackers.

The bottom line

Fast is a decision you make on the first screen: one light image, few scripts, no builder, static files. The typical small-business site in our data got that wrong and took seven seconds to show its main content. An AI can build you a site that loads in under two and a half, as long as the brief says so.

Explore ShiftPress

Build a site from a description or a design ZIP› Change your site by chat, and approve it before it goes live›