Open In App

How to create a Responsive Image in Bootstrap?

In Bootstrap, creating a responsive image is straightforward and ensures that the image scales appropriately based on the size of the viewport.

Syntax

<img src="image.jpg" class="img-fluid" alt="Responsive image">

Explanation:

Example

<div class="container">
<img src="image.jpg" class="img-fluid" alt="Responsive image">
</div>

Features

Article Tags :