Yes, you can overlay header text on top of a Lottie animation in Webflow by placing both elements within a parent container and using positioning to layer them correctly.
1. Prepare the Parent Container
- Add a Div Block to serve as the container for both the Lottie animation and the text.
- Set the position of this container to Relative so that child elements can be positioned absolutely inside it.
- Optional: Set the container’s dimensions (width, height) to match your Lottie animation or header size.
2. Add the Lottie Animation
- Drag in a Lottie element inside the container.
- Upload your Lottie JSON file or connect it via URL.
- Set the animation’s Position to Absolute, and anchors to Top: 0, Left: 0 — this ensures it fills the container.
- Optionally set Width: 100% and Height: 100% to scale it within the parent.
3. Add and Style the Header Text
- Drag in a Heading element (like H1) into the same container.
- Set the heading’s Position to Absolute, and center it using Top: 50%, Left: 50% with Transform: Translate(-50%, -50%).
- Style your text for readability (e.g., white color, drop shadow, font size).
- Make sure the text's z-index is set higher than the Lottie animation (e.g., z-index: 10).
4. Make It Responsive
- Use VW or REM units for text sizing so it scales on different breakpoints.
- Add responsive padding/margins to the parent container if needed.
- Adjust Lottie scaling behavior (e.g., “Contain” vs. “Cover”) via the container’s CSS or using Webflow’s layout settings.
Summary
To overlay header text on a Lottie animation in Webflow, place both in a relative-positioned container, set the Lottie file and text to absolute position, and adjust z-index and alignment. This allows the text to layer seamlessly over the animated background.