VOOZH about

URL: https://www.geeksforgeeks.org/bootstrap/bootstrap-4-badges/

⇱ Bootstrap 4 | Badges - GeeksforGeeks


  • Courses
  • Tutorials
  • Interview Prep

Bootstrap 4 | Badges

Last Updated : 29 Apr, 2022

The .badge class is used to add additional information to the content. For example, some websites associate a number of notifications to the link. The notification number is seen when logged in to a particular website which tells the numbers of news or notifications to see by clicking it.
Example: 
 

Output: 
 

👁 Image


Contextual Badges: The contextual classes (.badge-*) is used to change the color of badges. Badges can be used as part of links or button to provide a counter. Depending on how they used, badges must be confusing for the users. For this purpose different color of variations are used so that the user may not get confused.
Example: 
 

Output: 
 

👁 Image


Pill Badges: The .badge-pill class is used to make badges corner more rounded.
Example: 
 

Output: 
 

👁 Image


Badge inside an Element: Badges can be created inside an element.
Example: 
 

Output: 
 

👁 Image


Supported Browsers:

  • Google Chrome
  • Internet Explorer
  • Firefox
  • Opera
  • Safari
Comment
Article Tags:

Explore