What is the best way to add a fixed footer using Bootstrap? Pending Review
Asked on Sep 16, 2025
1 Answer
To add a fixed footer using Bootstrap, you can utilize the "fixed-bottom" class. This class ensures that the footer stays at the bottom of the viewport, regardless of the content height.
<!-- BEGIN COPY / PASTE -->
<footer class="bg-dark text-white text-center fixed-bottom py-3">
Fixed Footer Content
</footer>
<!-- END COPY / PASTE -->
- The "fixed-bottom" class makes the footer stick to the bottom of the viewport.
- Use "bg-dark" and "text-white" for styling the footer with a dark background and white text.
- The "py-3" class adds vertical padding for better spacing.
- Ensure that your content above the footer does not overlap by adding appropriate bottom margin or padding to the main content area.