> For the complete documentation index, see [llms.txt](https://docs.liveblog.pro/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.liveblog.pro/readme/publishing-to-readers/embedding-a-blog.md). Agents can also search and read this documentation through its [MCP server](https://docs.liveblog.pro/~gitbook/mcp).

# Embedding a blog

This page shows you how to put a blog on your own website: where to find the embed code, the choice between a responsive and a fixed height, the public address of the blog, and what readers can do in the embedded blog.

Readers never see the blog editor. They see the published blog, drawn by the theme of the blog, either inside a page of your website or at its public address.

{% hint style="warning" %}
**Want search engines to read your posts?** The usual embed code hides the blog from them. Use the search engine way instead: see [Embedding for search engines](#embedding-for-search-engines).
{% endhint %}

## Find the embed code

The embed code is in the blog settings. You can open them if you are an administrator, or if you have the Editor role and are the owner or a team member of the blog. Contributors cannot open the blog settings; ask an Editor for the code.

{% stepper %}
{% step %}

### Open the blog settings

Open the blog in the blog editor and click the gear icon in the top right corner.
{% endstep %}

{% step %}

### Find the Embed code field

On the **General** tab, scroll down to **Embed code**, below **Theme** and **Embed height**.
{% endstep %}

{% step %}

### Copy the code

Click the box to select all of the code, then copy it.
{% endstep %}
{% endstepper %}

<figure><img src="https://3069567940-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FiE9YRT74G1RgbPMObBM4%2Fuploads%2Fgit-blob-bcd309c72c59b651f2429408030fe80f497fb1b2%2Fembed-code.png?alt=media" alt="The General tab of the blog settings with the Theme field, the Embed height switch set to Responsive, the Embed code box and the public address of the blog below it" width="796"><figcaption><p>The embed code and the public address in the blog settings</p></figcaption></figure>

The code has two parts: a script line and an `iframe` that loads the blog. Paste both into the HTML of the page where the blog should appear, at the spot where you want it. Most content management systems have an HTML or embed block for this.

{% hint style="info" %}
Copy the whole code, script line included. The script makes the blog grow with its content and passes the address of your page to the blog for the links readers share.
{% endhint %}

You only paste the code once. Everything you publish later in the blog editor shows up in the embedded blog, and readers do not need to reload the page to see new posts.

## Embedding for search engines

Readers often find a live blog through a search engine. The usual embed code loads the blog in an `iframe`, a frame inside your page. Search engines read your page, but they may not count the posts inside the frame as part of it, so those posts may bring you fewer readers from search. If you want the posts to count as content of your page, publish the blog with Edge Side Includes (ESI). With ESI the posts are included in the page itself, so search engines can read them.

ESI needs two things:

1. **Turn on the option in the theme.** In the **Theme Manager**, open the **Settings** of the theme, turn on **Advanced settings**, and turn on **Optimise the Live Blog output for ESI**. See [Themes](https://docs.liveblog.pro/readme/publishing-to-readers/themes.md).
2. **Ask your web developer to set up your website.** The server or the cache of your website, for example Varnish, must be set up to handle ESI content.

After you turn the option on, the code in the blog settings changes. It no longer has the `iframe`, so the blog does not work as a normal `iframe` embed any more. Use the new code on every page that shows the blog.

To get a red LIVE label in Google Top stories, see [Google Top stories and the LIVE label](https://docs.liveblog.pro/readme/publishing-to-readers/google-top-stories.md).

{% hint style="info" %}
If you are not sure, keep the normal embed code. It works on every page without any set-up on your server.
{% endhint %}

## Responsive or fixed height

The **Embed height** switch above the code decides which code you get:

* **Responsive** (switch on): the embedded blog grows with its content, so your page scrolls as one page and readers never see a second scrollbar.
* **Normal** (switch off): the blog gets a fixed height of 715 pixels and readers scroll inside it.

The code in the box changes as soon as you flip the switch. Click **Save** if you want the blog settings to keep that choice. New blogs start with the default your administrator picked under **Default Embed Height** in the [general settings](https://docs.liveblog.pro/readme/administration/general-settings.md).

Some themes can be set up for publishing through Edge Side Includes. For a blog with such a theme, the **Embed height** switch is not shown and the box holds a different code, with a link to a help page that explains how to use it. See [Themes](https://docs.liveblog.pro/readme/publishing-to-readers/themes.md).

## The public address

Below the code is the public address of the blog. Click it to open the blog on its own, without your website around it. You can share that address as it is, for example while your web page is not ready yet.

Whether search engines may index the published blog is set in the theme, with **Block search engines**. See [Themes](https://docs.liveblog.pro/readme/publishing-to-readers/themes.md).

## What readers see

What the published blog looks like, and which of the controls below it shows, depends on its theme and the theme settings. Here is a blog in the default theme, **Liveblog 3 Default SEO Theme**.

<figure><img src="https://3069567940-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FiE9YRT74G1RgbPMObBM4%2Fuploads%2Fgit-blob-a8cf5fc502cbf399f6d07916e4cae6559217c54f%2Freader-view.png?alt=media" alt="A published blog in the default theme with the sort options, the Filter list, a pinned post and the share and permalink icons of a post numbered" width="752"><figcaption><p>A published blog as readers see it</p></figcaption></figure>

1. **Sort options**: **Editorial**, **Newest first** and **Oldest first**. **Editorial** keeps the order you set in the timeline.
2. **Filter**: shows only the posts with the tags the reader picks. See [Tags](https://docs.liveblog.pro/readme/writing-posts/tags.md).
3. **A pinned post**, with a pin icon next to its date. Pinned posts stay at the top. See [The timeline](https://docs.liveblog.pro/readme/writing-posts/the-timeline.md).
4. **Share and permalink**: the icons under a post, shown when the reader points at it. The share icon opens links to share the post on networks and messaging apps such as Facebook, LinkedIn, WhatsApp, Telegram and Twitter. The link icon is the permalink, the address of that one post.

Highlighted posts have a star next to their date and a shaded background. Polls are shown with their answers and a **VOTE** button.

### New and older posts

New posts appear in the blog on their own while readers have it open. The theme can also be set to show a button instead, so readers choose when to load them.

The blog first shows a set number of posts, ten in the default theme. At the bottom, readers click **Load more posts** to see older ones. The button goes away when there is nothing more to load.

### Shared posts

When the blog is embedded with the full code, the share links and the permalink of a post point to your page, not to the public address, with the post added to the address. A reader who follows such a link lands on your page.

## Where to go next

* [Themes](https://docs.liveblog.pro/readme/publishing-to-readers/themes.md): change how the published blog looks and which of these controls it shows.
* [What each theme supports](https://docs.liveblog.pro/readme/publishing-to-readers/what-each-theme-supports.md): compare the themes before you pick one.
* [Output channels](https://docs.liveblog.pro/readme/publishing-to-readers/output-channels.md): publish the same blog a second time with another theme, other adverts or only some tags, each with its own embed code.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.liveblog.pro/readme/publishing-to-readers/embedding-a-blog.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
