Alerts
Provide contextual feedback messages for typical user actions.
Basic example
A simple primary alert with an example link. Give it a click if you like.
A simple secondary alert with an example link. Give it a click if you like.
A simple success alert with an example link. Give it a click if you like.
A simple danger alert with an example link. Give it a click if you like.
A simple warning alert with an example link. Give it a click if you like.
A simple info alert with an example link. Give it a click if you like.
A simple light alert with an example link. Give it a click if you like.
A simple dark alert with an example link. Give it a click if you like.
<!-- Primary alert -->
<div class="alert alert-primary" role="alert">
A simple primary alert with <a href="#" class="alert-link">an example link</a>. Give it a click if you like.
</div>
<!-- Secondary alert -->
<div class="alert alert-secondary" role="alert">
A simple secondary alert with <a href="#" class="alert-link">an example link</a>. Give it a click if you like.
</div>
<!-- Success alert -->
<div class="alert alert-success" role="alert">
A simple success alert with <a href="#" class="alert-link">an example link</a>. Give it a click if you like.
</div>
<!-- Danger alert -->
<div class="alert alert-danger" role="alert">
A simple danger alert with <a href="#" class="alert-link">an example link</a>. Give it a click if you like.
</div>
<!-- Warning alert -->
<div class="alert alert-warning" role="alert">
A simple warning alert with <a href="#" class="alert-link">an example link</a>. Give it a click if you like.
</div>
<!-- Info alert -->
<div class="alert alert-info" role="alert">
A simple info alert with <a href="#" class="alert-link">an example link</a>. Give it a click if you like.
</div>
<!-- Light alert -->
<div class="alert alert-light" role="alert">
A simple light alert with <a href="#" class="alert-link">an example link</a>. Give it a click if you like.
</div>
<!-- Dark alert -->
<div class="alert alert-dark" role="alert">
A simple dark alert with <a href="#" class="alert-link">an example link</a>. Give it a click if you like.
</div>
Alert with icon
A simple primary alert with an example link. Give it a click if you like.
A simple secondary alert with an example link. Give it a click if you like.
A simple success alert with an example link. Give it a click if you like.
A simple danger alert with an example link. Give it a click if you like.
A simple warning alert with an example link. Give it a click if you like.
A simple info alert with an example link. Give it a click if you like.
A simple light alert with an example link. Give it a click if you like.
A simple dark alert with an example link. Give it a click if you like.
<!-- Primary alert -->
<div class="alert d-flex alert-primary" role="alert">
<i class="ci-bell lead me-3"></i>
<div>
A simple primary alert with <a href="#" class="alert-link">an example link</a>. Give it a click if you like.
</div>
</div>
<!-- Secondary alert -->
<div class="alert d-flex alert-secondary" role="alert">
<i class="ci-clock lead me-3"></i>
<div>
A simple secondary alert with <a href="#" class="alert-link">an example link</a>. Give it a click if you like.
</div>
</div>
<!-- Success alert -->
<div class="alert d-flex alert-success" role="alert">
<i class="ci-check lead me-3"></i>
<div>
A simple success alert with <a href="#" class="alert-link">an example link</a>. Give it a click if you like.
</div>
</div>
<!-- Danger alert -->
<div class="alert d-flex alert-danger" role="alert">
<i class="ci-close-round lead me-3"></i>
<div>
A simple danger alert with <a href="#" class="alert-link">an example link</a>. Give it a click if you like.
</div>
</div>
<!-- Warning alert -->
<div class="alert d-flex alert-warning" role="alert">
<i class="ci-alert lead me-3"></i>
<div>
A simple warning alert with <a href="#" class="alert-link">an example link</a>. Give it a click if you like.
</div>
</div>
<!-- Info alert -->
<div class="alert d-flex alert-info" role="alert">
<i class="ci-alert-octagon lead me-3"></i>
<div>
A simple info alert with <a href="#" class="alert-link">an example link</a>. Give it a click if you like.
</div>
</div>
<!-- Light alert -->
<div class="alert d-flex alert-light" role="alert">
<i class="ci-unlock lead me-3"></i>
<div>
A simple light alert with <a href="#" class="alert-link">an example link</a>. Give it a click if you like.
</div>
</div>
<!-- Dark alert -->
<div class="alert d-flex alert-dark" role="alert">
<i class="ci-map-pin-outline lead me-3"></i>
<div>
A simple dark alert with <a href="#" class="alert-link">an example link</a>. Give it a click if you like.
</div>
</div>
Dismissible alerts
Primary alert: Dismiss me by clicking the close button on the right.
Secondary alert: Dismiss me by clicking the close button on the right.
Success alert: Dismiss me by clicking the close button on the right.
Danger alert: Dismiss me by clicking the close button on the right.
Warning alert: Dismiss me by clicking the close button on the right.
Info alert: Dismiss me by clicking the close button on the right.
Light alert: Dismiss me by clicking the close button on the right.
Dark alert: Dismiss me by clicking the close button on the right.
<!-- Primary alert -->
<div class="alert alert-primary alert-dismissible fade show" role="alert">
<span class="fw-bold">Primary alert:</span> Dismiss me by clicking the close button on the right.
<button type="button" class="btn-close" data-bs-dismiss="alert" aria-label="Close"></button>
</div>
<!-- Secondary alert -->
<div class="alert alert-secondary alert-dismissible fade show" role="alert">
<span class="fw-bold">Secondary alert:</span> Dismiss me by clicking the close button on the right.
<button type="button" class="btn-close" data-bs-dismiss="alert" aria-label="Close"></button>
</div>
<!-- Success alert -->
<div class="alert alert-success alert-dismissible fade show" role="alert">
<span class="fw-bold">Success alert:</span> Dismiss me by clicking the close button on the right.
<button type="button" class="btn-close" data-bs-dismiss="alert" aria-label="Close"></button>
</div>
<!-- Danger alert -->
<div class="alert alert-danger alert-dismissible fade show" role="alert">
<span class="fw-bold">Danger alert:</span> Dismiss me by clicking the close button on the right.
<button type="button" class="btn-close" data-bs-dismiss="alert" aria-label="Close"></button>
</div>
<!-- Warning alert -->
<div class="alert alert-warning alert-dismissible fade show" role="alert">
<span class="fw-bold">Warning alert:</span> Dismiss me by clicking the close button on the right.
<button type="button" class="btn-close" data-bs-dismiss="alert" aria-label="Close"></button>
</div>
<!-- Info alert -->
<div class="alert alert-info alert-dismissible fade show" role="alert">
<span class="fw-bold">Info alert:</span> Dismiss me by clicking the close button on the right.
<button type="button" class="btn-close" data-bs-dismiss="alert" aria-label="Close"></button>
</div>
<!-- Light alert -->
<div class="alert alert-light alert-dismissible fade show" role="alert">
<span class="fw-bold">Light alert:</span> Dismiss me by clicking the close button on the right.
<button type="button" class="btn-close" data-bs-dismiss="alert" aria-label="Close"></button>
</div>
<!-- Dark alert -->
<div class="alert alert-dark alert-dismissible fade show" role="alert">
<span class="fw-bold">Dark alert:</span> Dismiss me by clicking the close button on the right.
<button type="button" class="btn-close btn-close-white" data-bs-dismiss="alert" aria-label="Close"></button>
</div>
Additional content
Well done!
Aww yeah, you successfully read this important alert message. This example text is going to run a bit longer so that you can see how spacing within an alert works with this kind of content.
Whenever you need to, be sure to use margin utilities to keep things nice and tidy.
<!-- Primary alert -->
<div class="alert alert-primary" role="alert">
<h4 class="pt-2 alert-heading">Well done!</h4>
<p>Aww yeah, you successfully read this important alert message. This example text is going to run a bit longer so that you can see how spacing within an alert works with this kind of content.</p>
<hr>
<p class="pt-3 mb-2">Whenever you need to, be sure to use margin utilities to keep things nice and tidy.</p>
</div>