Table of Contents
Integrating your Pressroom into your own website allows visitors to stay informed with the latest news while keeping them engaged on your platform. Follow this step-by-step guide to seamlessly embed your Pressroom.
If you still need help with the integration, please contact NewsMachine Support at support@newsmachine.com.
1. Embed your press room on a regular website
Step 1: Find the URL for your Press Room
Before you add the Press Room to your website, you’ll need the URL for your Press Room.
Use the URL that is registered for your organization in NewsMachine.
Example: https://newsmachine.pmembedded.newsmachine.com/.
If you have your own subdomain (CNAME) registered with NewsMachine, you can use that URL instead.
For example: src="https://subdomän.dindomän.com/".
Step 2: Add the embed code
The easiest way to embed your Press Room is to add an iframe to your website.
Copy the code below and replace YOUR-PRESS-ROOM-URL with the URL for your press room:
<iframe
src="https://DIN-PRESSRUMS-URL/"
width="100%"
height="1400"
style="border: 0;"
title="Press Room">
</iframe>
Exempel:
<iframe
src="https://newsmachine.pmembedded.newsmachine.com/"
width="100%"
height="1400"
style="border: 0;"
title="Press Room">
</iframe>
The iframe element displays your Press Room directly on your website.
Step 2: Customize the embed
- Width & Height: Adjust the <iframe> attributes for optimal display.
- CSS styling: Customize the look to match your website design. Log in to your Newsmachine account, navigate to Press releases in the main menu, then click on Press Room in the submenu and scroll down to the CSS editor.
- Once you have made the necessary adjustments, click Save.
Step 3: Adjust the size
You can adjust the “height” value to fit the website’s layout.
Example: height=”1200″ or: height=”1600″
The width=”100%” setting causes Pressrummet to fill the available width of its container.
Optional: Automatic iframe height
If your Press Room is configured to send its height to the parent website, you can use the following code to automatically adjust the height of the iframe.
<iframe
id="pressFrame"
src="https://DIN-PRESSRUMS-URL/"
width="100%"
height="1400"
style="border: 0; display: block;"
title="Press Room">
</iframe>
<script>
(function () {
const iframe = document.getElementById('pressFrame');
if (!iframe) {
return;
}
const allowedOrigin = new URL(iframe.src, window.location.href).origin;
window.addEventListener('message', function (event) {
// Acceptera endast meddelanden från det inbäddade Pressrummet.
if (
event.source !== iframe.contentWindow ||
event.origin !== allowedOrigin
) {
return;
}
try {
const data =
typeof event.data === 'string'
? JSON.parse(event.data)
: event.data;
if (data && Number.isFinite(Number(data.height))) {
iframe.style.height = `${Number(data.height) + 1}px`;
}
} catch (error) {
console.error('Unable to process Press Room resize message.', error);
}
});
})();
</script>
Important: The URL in the src attribute must be the actual URL of your Press Room. You do not need to change allowedOrigin manually—it is determined automatically based on the iframe URL.
Step 4: Customize the Press Room
You can customize the appearance of your Press Room from your NewsMachine account.
Log in to your NewsMachine account and go to:
Press Releases → Press Room → CSS Editor
Make the desired changes and click Save.
Step 5: Test the integration
Visit the page where your Press Room is located and check that:
- The press room is loading correctly.
- The press room is displayed at the correct width.
- The height is sufficient to display the content.
- The links and buttons in the Press Room are working properly.
- The press room works on both computers and mobile devices.
If you’re using the version with automatic height, you should also check that the iframe resizes correctly when you navigate between different pages in the Press Room.
2. Embed your Press Room on a WordPress website
There are several ways to add your Press Room to a WordPress site, depending on which editor or page builder you use.
2.1 WordPress Block Editor (Gutenberg)

If you’re using the WordPress Block Editor, the easiest way is to use a Custom HTML block. WordPress provides this block specifically for adding custom HTML, such as iframe code.
Step 1: Open the page
Open the WordPress page or post where you want to display your Press Room.
Step 2: Add a Custom HTML block
Click the + button to add a new block.
Search for ” Custom HTML ” and select it.
Step 3: Paste the iframe code
Paste the following code into the Custom HTML block:
<iframe
src="https://DIN-PRESSRUMS-URL/"
width="100%"
height="1400"
style="border: 0; display: block;"
title="Press Room">
</iframe>Replace DIN-PRESSRUMS-URL with the actual URL for your Press Room.
Example:
<iframe
src="https://newsmachine.pmembedded.newsmachine.com/"
width="100%"
height="1400"
style="border: 0; display: block;"
title="Press Room">
</iframe>Step 4: Preview and Publish
Use the block’s preview to check the results, and then preview the page on the website’s public site before publishing it.
You can change the “height” value if you need more or less space for the Press Room.
Automatic Height in WordPress
If you want the iframe to resize automatically, you can use the advanced code provided in the ” Optional: Automatic iframe Height ” section above.
Paste the entire code into the Custom HTML block.
2.2 WordPress Classic Editor
If you’re using the Classic Editor:
Step 1: Open the page or post
Open the page or post where you want to add the Press Room.
Step 2: Switch to Text/HTML mode
Switch from Visual to Text editing mode.

Step 3: Add the iframe
Paste the following code where you want the Press Room to appear:
<iframe
src="https://DIN-PRESSRUMS-URL/"
width="100%"
height="1400"
style="border: 0; display: block;"
title="Press Room">
</iframe>Replace DIN-PRESSRUMS-URL with the actual URL for your Press Room.
Step 4: Save and Preview
Save or refresh the page and preview it on your website.
2.3 Using a WordPress Plugin
If your WordPress installation does not allow you to add iframe HTML directly, you can use a reputable iframe or embed plugin that is compatible with your version of WordPress.
Follow the plugin’s instructions to add an iframe, and use the URL for your Press Room as the iframe source.
For security reasons, WordPress and certain plugins or hosting environments may restrict certain HTML or JavaScript. If you are unable to save the iframe code, contact your WordPress administrator or hosting provider.
2.4. Insert an iframe with Elementor

If you’re using Elementor, we recommend using the HTML widget. Elementor’s HTML widget supports HTML, CSS, JavaScript, and shortcodes.
Method 1: Using the HTML widget
Step 1: Open the page in Elementor
Open the page where you want to add the Press Room and click ” Edit with Elementor.”
Step 2: Add the HTML widget
Search for ” HTML ” in Elementor’s widget panel.
Drag the HTML widget to the location where you want the Press Room to appear.
Step 3: Paste the iframe code
Paste the following code into the HTML widget:
<iframe
src="https://DIN-PRESSRUMS-URL/"
width="100%"
height="1400"
style="border: 0; display: block;"
title="Press Room">
</iframe>Replace DIN-PRESSRUMS-URL with the actual URL for your Press Room.
Step 4: Preview the page
Save the page and preview it on your website.
Check the Press Room on different screen sizes to ensure that it displays correctly.
Automatic height
If your Press Room supports automatic resizing of iframes, you can paste the entire code for automatic height from the ” Optional: Automatic iframe Height” section into the Elementor HTML widget.
Method 2: Shortcode Widget
If you’re using a WordPress plugin or another integration that provides a shortcode for iframe embeds, you can add this shortcode using Elementor’s Shortcode widget.
Do not paste regular iframe HTML into the Shortcode widget unless the shortcode or plugin specifically supports HTML iframe code.
For standard iframe HTML, use the HTML widget instead.
2.5 Divi
If you’re using the Divi Builder, you can add the Press Room using the Code Module. Divi’s Code Module supports HTML, CSS, JavaScript, and shortcodes.
Method 1: Code Module
Step 1: Open the page in Divi
Open the page where you want to add the Press Room and launch the Divi Builder.
Step 2: Add a Code Module
Add a Code Module to the section where you want the Press Room to appear.
Step 3: Paste the iframe code
Paste the following code:

<iframe
src="https://DIN-PRESSRUMS-URL/"
width="100%"
height="1400"
style="border: 0; display: block;"
title="Press Room">
</iframe>Replace DIN-PRESSRUMS-URL with the actual URL for your Press Room.
Step 4: Save and Preview
Save the module and preview the page.
Check the Press Room on your computer, tablet, and phone.
Automatic height
If your Press Room supports automatic resizing of iframes, you can use the entire code for automatic height from the ” Optional: Automatic iframe Height” section.
Paste the code into the Divis Code Module.
Method 2: Text Module
You can also use a Divi Text Module if your configuration allows iframe HTML.
Add a Text Module, switch to HTML/Text editing mode, and paste the iframe code.
Save the module and preview the page.
3. Customize Your Press Room
You can customize the appearance of your Press Room from your NewsMachine account.
Log in to your NewsMachine account and go to:
Press Releases → Press Room → CSS Editor
Use the CSS editor to customize the appearance of your Press Room.
Once you’ve made your changes, click Save.
The CSS used within the Press Room controls the appearance of the embedded content. The website’s own CSS can also affect the iframe container, such as its width, margins, and padding.
4. Test the integration
Once you’ve added the Press Room to your website, you should thoroughly test the integration.
Check that the Press Room:
- load correctly
- displayed at the correct width
- is high enough
- Works on computers, tablets, and cell phones
- has working links and buttons.
5. Troubleshooting
The iframe is not displayed
Check that:
- The URL for the Press Room is correct.
- The URL uses https://.
- the iframe code has not been removed or modified by WordPress, a plugin, or the site’s editor.
- Your website or hosting provider does not block iframe content.
WordPress removes the iframe code
Some user roles in WordPress do not have permission to use certain HTML elements. WordPress may therefore remove that content when the page is saved.
If this happens, ask your WordPress administrator to add the iframe code or grant you the necessary permissions.
The press room is too short
Increase the iframe height.
Example: height=”1600″
If you are using the version with automatic height, make sure you have copied the entire code and that the Press Room is configured to send its height to the parent page.
The press room has a scroll bar
First, check that the iframe is tall enough to display the content.
If you’re using the version with automatic height adjustment, make sure the automatic resizing feature is working properly.
Avoid hiding the scroll bar as a temporary solution, because visitors might not realize that there is additional content.
The press room does not automatically change size
If you’re using the version with automatic height adjustment:
- Make sure the src attribute contains the correct URL to the Press Room.
- Make sure you’ve copied the entire JavaScript code.
- Make sure your website platform hasn’t deleted
- Check your browser’s developer console for JavaScript errors.
- If the problem persists, contact NewsMachine Support.
The iframe is blocked
Some WordPress themes, security plugins, Content Security Policies (CSP), or hosting configurations may restrict iframe content.
If your iframe is blocked, contact your website administrator or hosting provider and ask them to check whether iframe content from your NewsMachine Press Room domain is allowed.
6. Do you need help?
If you need help embedding your Press Room or troubleshooting the integration, please contact NewsMachine Support at: