To center a third-party affiliate widget in your Webflow page, you need to control the alignment of the container holding the code. Webflow typically uses a Embed element for such widgets.
<iframe>
).There are two effective methods:
Flexbox Method:
Select the wrapper Div.
In the Style panel, set Display: Flex
.
Set Justify: Center and optionally Align: Center if vertical centering is also needed.
Margin Auto Method (for fixed-width widgets):
Set a fixed width (e.g., 300px) on the wrapper Div.
Set margin-left: auto and margin-right: auto.
Ensure the parent container has Display: Block
or is wide enough to contain it.
To center a third-party affiliate widget in Webflow, wrap the Embed element in a Div, then use either Flexbox or automatic margins to horizontally center it. This ensures the widget remains cleanly aligned across screen sizes.