> For clean Markdown content of this page, append .md to this URL. For the complete documentation index, see https://buildwithfern.com/learn/llms.txt.

## Dynamic OG images  \[#dynamic-og-images]

seo, docs.yml, frontmatter

Fern can now automatically generate unique Open Graph images for each page of your docs site. Set `og:dynamic` to true in your `docs.yml` metadata to enable it. Pages with an `og:image` set in frontmatter will use the specified image instead.

You can also use `og:dynamic:background-image` to set a custom background image for your dynamically generated OG image, instead of a solid color.

**`docs.yml`**

```yaml docs.yml
metadata:
  og:dynamic: true
  og:dynamic:background-image: ./images/og-background.png # optional
```

Read the docs