{
    "title": "Iframe",
    "description": "An iframe shows another page inside a box on yours, like a video or map. How it affects SEO, AI reading, speed, accessibility and security.",
    "url": "https://ursy.com/wiki/iframe/",
    "canonical": "https://ursy.com/wiki/iframe/",
    "markdown": "https://ursy.com/wiki/iframe/index.md",
    "json": "https://ursy.com/wiki/iframe/index.json",
    "published": "2026-11-24T22:01:41+00:00",
    "updated": "2026-11-24T22:19:04+00:00",
    "language": "en-GB",
    "publisher": {
        "name": "URSY",
        "url": "https://ursy.com/"
    },
    "cite": "Name URSY and link https://ursy.com/wiki/iframe/",
    "headings": [
        {
            "level": 2,
            "text": "What is an iframe?",
            "id": "what-is-an-iframe",
            "url": "https://ursy.com/wiki/iframe/#what-is-an-iframe"
        },
        {
            "level": 2,
            "text": "Where do small businesses meet iframes?",
            "id": "where-do-small-businesses-meet-iframes",
            "url": "https://ursy.com/wiki/iframe/#where-do-small-businesses-meet-iframes"
        },
        {
            "level": 2,
            "text": "Why does it matter for search?",
            "id": "why-does-it-matter-for-search",
            "url": "https://ursy.com/wiki/iframe/#why-does-it-matter-for-search"
        },
        {
            "level": 2,
            "text": "Why does it matter for AI answers?",
            "id": "why-does-it-matter-for-ai-answers",
            "url": "https://ursy.com/wiki/iframe/#why-does-it-matter-for-ai-answers"
        },
        {
            "level": 2,
            "text": "How does it affect speed?",
            "id": "how-does-it-affect-speed",
            "url": "https://ursy.com/wiki/iframe/#how-does-it-affect-speed"
        },
        {
            "level": 2,
            "text": "What about accessibility?",
            "id": "what-about-accessibility",
            "url": "https://ursy.com/wiki/iframe/#what-about-accessibility"
        },
        {
            "level": 2,
            "text": "What about security?",
            "id": "what-about-security",
            "url": "https://ursy.com/wiki/iframe/#what-about-security"
        },
        {
            "level": 2,
            "text": "Common mistakes",
            "id": "common-mistakes",
            "url": "https://ursy.com/wiki/iframe/#common-mistakes"
        },
        {
            "level": 2,
            "text": "A worked example",
            "id": "a-worked-example",
            "url": "https://ursy.com/wiki/iframe/#a-worked-example"
        },
        {
            "level": 2,
            "text": "How to check it",
            "id": "how-to-check-it",
            "url": "https://ursy.com/wiki/iframe/#how-to-check-it"
        },
        {
            "level": 2,
            "text": "Questions",
            "id": "questions",
            "url": "https://ursy.com/wiki/iframe/#questions"
        },
        {
            "level": 3,
            "text": "Does Google index text inside an iframe?",
            "id": "does-google-index-text-inside-an-iframe",
            "url": "https://ursy.com/wiki/iframe/#does-google-index-text-inside-an-iframe"
        },
        {
            "level": 3,
            "text": "Are iframes bad for SEO?",
            "id": "are-iframes-bad-for-seo",
            "url": "https://ursy.com/wiki/iframe/#are-iframes-bad-for-seo"
        },
        {
            "level": 3,
            "text": "Should I lazy load every iframe?",
            "id": "should-i-lazy-load-every-iframe",
            "url": "https://ursy.com/wiki/iframe/#should-i-lazy-load-every-iframe"
        },
        {
            "level": 3,
            "text": "Can I stop other sites framing my pages?",
            "id": "can-i-stop-other-sites-framing-my-pages",
            "url": "https://ursy.com/wiki/iframe/#can-i-stop-other-sites-framing-my-pages"
        },
        {
            "level": 2,
            "text": "Related words",
            "id": "related-words",
            "url": "https://ursy.com/wiki/iframe/#related-words"
        },
        {
            "level": 2,
            "text": "Sources",
            "id": "sources",
            "url": "https://ursy.com/wiki/iframe/#sources"
        }
    ],
    "links": [
        {
            "text": "search engines",
            "url": "https://ursy.com/wiki/search-engine/",
            "internal": true
        },
        {
            "text": "iframe element",
            "url": "https://developer.mozilla.org/en-US/docs/Web/HTML/Reference/Elements/iframe",
            "internal": false
        },
        {
            "text": "HTML",
            "url": "https://ursy.com/wiki/html/",
            "internal": true
        },
        {
            "text": "CSS",
            "url": "https://ursy.com/wiki/css/",
            "internal": true
        },
        {
            "text": "URL",
            "url": "https://ursy.com/wiki/url/",
            "internal": true
        },
        {
            "text": "Google",
            "url": "https://ursy.com/wiki/google/",
            "internal": true
        },
        {
            "text": "search crawler",
            "url": "https://ursy.com/wiki/search-crawler/",
            "internal": true
        },
        {
            "text": "thin content",
            "url": "https://ursy.com/wiki/thin-content/",
            "internal": true
        },
        {
            "text": "January 2022 post",
            "url": "https://developers.google.com/search/blog/2022/01/robots-meta-tag-indexifembedded",
            "internal": false
        },
        {
            "text": "noindex",
            "url": "https://ursy.com/wiki/noindex/",
            "internal": true
        },
        {
            "text": "meta tag",
            "url": "https://ursy.com/wiki/meta-tag/",
            "internal": true
        },
        {
            "text": "X-Robots-Tag",
            "url": "https://ursy.com/wiki/x-robots-tag/",
            "internal": true
        },
        {
            "text": "robots meta tag documentation",
            "url": "https://developers.google.com/search/docs/crawling-indexing/robots-meta-tag",
            "internal": false
        },
        {
            "text": "AI crawler",
            "url": "https://ursy.com/wiki/ai-crawler/",
            "internal": true
        },
        {
            "text": "large language model",
            "url": "https://ursy.com/wiki/large-language-model/",
            "internal": true
        },
        {
            "text": "AI hallucination",
            "url": "https://ursy.com/wiki/ai-hallucination/",
            "internal": true
        },
        {
            "text": "answer engine optimisation",
            "url": "https://ursy.com/wiki/answer-engine-optimisation/",
            "internal": true
        },
        {
            "text": "lazy loading iframes",
            "url": "https://web.dev/articles/iframe-lazy-loading",
            "internal": false
        },
        {
            "text": "Largest Contentful Paint",
            "url": "https://ursy.com/wiki/largest-contentful-paint/",
            "internal": true
        },
        {
            "text": "Core Web Vitals",
            "url": "https://ursy.com/wiki/core-web-vitals/",
            "internal": true
        },
        {
            "text": "above the fold",
            "url": "https://ursy.com/wiki/above-the-fold/",
            "internal": true
        },
        {
            "text": "lazy loading",
            "url": "https://ursy.com/wiki/lazy-loading/",
            "internal": true
        },
        {
            "text": "page speed",
            "url": "https://ursy.com/wiki/page-speed/",
            "internal": true
        },
        {
            "text": "web accessibility",
            "url": "https://ursy.com/wiki/web-accessibility/",
            "internal": true
        },
        {
            "text": "frame-ancestors",
            "url": "https://developer.mozilla.org/en-US/docs/Web/HTTP/Reference/Headers/Content-Security-Policy/frame-ancestors",
            "internal": false
        },
        {
            "text": "HTTP",
            "url": "https://ursy.com/wiki/http/",
            "internal": true
        },
        {
            "text": "canonical tags",
            "url": "https://ursy.com/wiki/canonical-tag/",
            "internal": true
        },
        {
            "text": "internal linking",
            "url": "https://ursy.com/wiki/internal-linking/",
            "internal": true
        },
        {
            "text": "AI assistant",
            "url": "https://ursy.com/wiki/ai-assistant/",
            "internal": true
        },
        {
            "text": "AI Readiness Checker",
            "url": "https://ursy.com/ai-readiness-checker/",
            "internal": true
        },
        {
            "text": "HTTP Header Checker",
            "url": "https://ursy.com/http-header-checker/",
            "internal": true
        },
        {
            "text": "Security Headers Checker",
            "url": "https://ursy.com/security-headers-checker/",
            "internal": true
        },
        {
            "text": "Link Checker",
            "url": "https://ursy.com/broken-link-checker/",
            "internal": true
        },
        {
            "text": "Page Speed Checker",
            "url": "https://ursy.com/page-speed-checker/",
            "internal": true
        },
        {
            "text": "Core Web Vitals calculator",
            "url": "https://ursy.com/webmaster-tools/core-web-vitals-calculator/",
            "internal": true
        },
        {
            "text": "Google Search Console",
            "url": "https://ursy.com/wiki/google-search-console/",
            "internal": true
        },
        {
            "text": "URL Inspection",
            "url": "https://ursy.com/wiki/url-inspection/",
            "internal": true
        },
        {
            "text": "JavaScript SEO",
            "url": "https://ursy.com/wiki/javascript-seo/",
            "internal": true
        },
        {
            "text": "Rendering",
            "url": "https://ursy.com/wiki/rendering/",
            "internal": true
        },
        {
            "text": "Video SEO",
            "url": "https://ursy.com/wiki/video-seo/",
            "internal": true
        }
    ],
    "words": 1215,
    "text": "An iframe is an HTML element that shows another web page or document inside a box on your own page, such as a YouTube video, a map, a booking form or a payment widget. The name means “inline frame”. The content inside the box lives at its own address, so search engines and AI systems usually treat it as belonging to that address, not to your page. What is an iframe? MDN, the reference for web developers, describes the iframe element as a nested browsing context that embeds one document in another. In plain words: a window cut into your page that looks out onto a different page. That inner page has its own HTML, its own CSS, its own scripts and its own URL. A simple one looks like this: <iframe src=\"https://www.example.org/map\" title=\"Map of our shop\" loading=\"lazy\"></iframe> The src attribute says what to load. The title says what it is. The loading attribute says when to load it. Where do small businesses meet iframes? Video players from YouTube or Vimeo. Maps showing where you are. Booking calendars, chat boxes and review widgets from outside services. Card payment fields, which payment companies often load in a frame so card numbers never touch your page. Social media posts and some advertising. You may have dozens of them without knowing. Many page builders and plugins add them for you. Why does it matter for search? Text inside an iframe is not really your text. It sits at another address, and that address is what gets crawled and indexed. Google’s robots rules page says Google is allowed to index the content of a page when it is embedded in another page through iframes. That content is still credited to its source. So if your opening hours, prices or product details only appear inside a frame, your own page may look thin to a search crawler, and that is a quick route to thin content. There is a control for the owner of the embedded page. Google added the indexifembedded rule in a January 2022 post. Used together with noindex, it says: do not show this page on its own, but do let its content count when it is embedded through an iframe. The post gives the meta tag version and an X-Robots-Tag header version. Google’s robots meta tag documentation adds that it only has an effect when paired with noindex. Why does it matter for AI answers? An AI crawler fetches your page to read it. Many of them do not run scripts and do not follow every frame. If the facts a customer needs are locked in an embedded widget, a large language model may never see them, or may credit them to the widget’s company. Then an assistant may guess, which is how an AI hallucination about your firm starts. For answer engine optimisation, the rule is simple: put the key facts in plain text on your own page, and use the frame for the interactive extra. How does it affect speed? Every frame is a whole extra page to fetch. MDN warns that each one adds memory and computing cost. web.dev’s guide to lazy loading iframes says built-in lazy loading is well supported across the major browsers. It reports that lazy loading YouTube embeds saves around 500 KB on the first page load. Adding loading=\"lazy\" to frames lower down the page lets the browser wait until a visitor scrolls near them. That frees bandwidth for your Largest Contentful Paint and helps your Core Web Vitals. Do not lazy load a frame that sits above the fold. See lazy loading and page speed. What about accessibility? Give every frame a title. MDN says the value should concisely describe the embedded content. Without one, screen reader users have to go inside the frame to work out what it is. That is confusing on a page with several frames. It is part of good web accessibility. What about security? Frames work both ways. You can embed others, and others can embed you. Someone could put your login or checkout page in an invisible frame and trick people into clicking. This is called clickjacking. To stop it, send a Content-Security-Policy header with frame-ancestors. MDN notes that leaving it unset allows anything. The value 'none' blocks all embedding, much like the older X-Frame-Options: deny. MDN also says this rule cannot go in a meta tag; it must be an HTTP header. When you embed other people’s content, the sandbox attribute removes powers such as running scripts or opening pop-ups. MDN strongly discourages combining allow-scripts with allow-same-origin for same-origin content, because the frame can then remove its own sandbox. Common mistakes Key facts only in a widget. Prices, hours or reviews shown only inside a frame are not your page’s words. No title. Screen readers announce an unnamed frame. Everything loads at once. Five embeds near the bottom of the page all load before anyone scrolls. No frame-ancestors rule. Your pages can be framed by any site. Whole pages built from frames. Old sites that frame their own content split one page into several URLs, which muddles canonical tags and internal linking. A worked example A café embeds a booking widget, a map and an Instagram feed on its contact page. Element Before After Booking widget Hours and phone number only inside it Hours and phone written as page text above it Map No title, loads at once title=”Map of the café”, loading=”lazy” Instagram feed Loads at once at the bottom loading=”lazy” Page header No frame-ancestors frame-ancestors ‘self’ Now a search engine and an AI assistant both read the hours as the café’s own words, and the page loads less on first view. How to check it View the page source and search for <iframe. Note each src. Test what text a machine reads without scripts, using our AI Readiness Checker. Check your response headers for frame-ancestors and X-Frame-Options with our HTTP Header Checker. The Security Headers Checker grades them. Use the Link Checker to find frames whose source has moved or died. For speed, the Page Speed Checker (coming soon) shows heavy embeds. Our free Core Web Vitals calculator explains the scores. In Google Search Console, use URL Inspection to see the rendered HTML Google got. Questions Does Google index text inside an iframe? It can, but it is tied to the embedded page’s address. Do not rely on it for your own page. Are iframes bad for SEO? No. A video or map in a frame is fine. The problem is when the frame holds the only copy of your key facts. Should I lazy load every iframe? Only those below the first screen. A frame visible on load should load straight away. Can I stop other sites framing my pages? Yes. Send Content-Security-Policy: frame-ancestors 'self' as a header. Related words JavaScript SEO Rendering Lazy loading X-Robots-Tag Video SEO Sources MDN: the iframe element, checked 24 November 2026 MDN: CSP frame-ancestors, checked 24 November 2026 web.dev: It’s time to lazy-load offscreen iframes, checked 24 November 2026 Google Search Central: Robots meta tag, data-nosnippet and X-Robots-Tag specifications, checked 24 November 2026 Google Search Central Blog: Letting Google index embedded content (21 January 2022), checked 24 November 2026 Updated 24 November 2026 by URSY.",
    "source": "https://ursy.com/wiki/iframe/"
}