# Retrieve the HTML content from a Confluence page to display it exactly as it appears in Confluence

**URL:** <https://community.developer.atlassian.com/t/retrieve-the-html-content-from-a-confluence-page-to-display-it-exactly-as-it-appears-in-confluence/81166>\
**Category:** Confluence Cloud\
**Tags:** confluence-cloud, rest-api\
**Created:** [June 25, 2024, 12:51pm UTC](https://community.developer.atlassian.com/t/retrieve-the-html-content-from-a-confluence-page-to-display-it-exactly-as-it-appears-in-confluence/81166 "2024-06-25T12:51:23Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![OlivierS](https://avatars.discourse-cdn.com/v4/letter/o/f07891/32.png) [@OlivierS](https://community.developer.atlassian.com/u/OlivierS)\
**Post date:** [June 25, 2024, 12:51pm UTC](https://community.developer.atlassian.com/t/retrieve-the-html-content-from-a-confluence-page-to-display-it-exactly-as-it-appears-in-confluence/81166/1 "2024-06-25T12:51:24Z")

</div>

Hi,

I’m a bit lost and need assistance. I’m trying to retrieve the HTML content of an existing Confluence page, including the styles, images, and all other elements, so it looks exactly the same as it does in Confluence.

What is the best way to accomplish this using the REST API?

Thank you.

---

<div class="post-metadata">

**Author:** ![AaronCollier](https://avatars.discourse-cdn.com/v4/letter/a/e274bd/32.png) [@AaronCollier](https://community.developer.atlassian.com/u/AaronCollier)\
**Post date:** [July 12, 2024, 9:30am UTC](https://community.developer.atlassian.com/t/retrieve-the-html-content-from-a-confluence-page-to-display-it-exactly-as-it-appears-in-confluence/81166/2 "2024-07-12T09:30:15Z")

</div>

I’d suggest [getting a page by ID](https://developer.atlassian.com/cloud/confluence/rest/v2/api-group-page/#api-pages-id-get) with a `body-format` of `styled_view` (which comes with styles, though possibly not the global Confluence ones). That’d be a URL like this: `https://{your-domain}/wiki/api/v2/pages/{id}?body-format=styled_view`
