Bootstrap 4 provides different styles of buttons Bootstrap provides some great customization features such as type or style, size, rulers, etc.
![](https://rathorji.in/post-media/d0836eedc9fecb9a0a9240fb6b69869a/111e4f0a84388c8f9ad167591f6ba9d8.jpg)
The .btn classes are designed to be used with the <button> element. However, you can also use these classes in <a> or <input> elements
#example.html
<button type="button" class="btn btn-primary">Primary</button>
<button type="button" class="btn btn-secondary">Secondary</button>
<button type="button" class="btn btn-success">Success</button>
<button type="button" class="btn btn-danger">Danger</button>
<button type="button" class="btn btn-warning">Warning</button>
<button type="button" class="btn btn-info">Info</button>
<button type="button" class="btn btn-light">Light</button>
<button type="button" class="btn btn-dark">Dark</button>
<button type="button" class="btn btn-link">Link</button>
Outline buttons
.btn-outline- * ones to remove all images and background colors on any button.
![](https://rathorji.in/post-media/d0836eedc9fecb9a0a9240fb6b69869a/a944642e7d52688a41c08a30b1d60721.jpg)
#button-outline.html
<button type="button" class="btn btn-outline-primary">Primary</button>
<button type="button" class="btn btn-outline-secondary">Secondary</button>
<button type="button" class="btn btn-outline-success">Success</button>
<button type="button" class="btn btn-outline-danger">Danger</button>
<button type="button" class="btn btn-outline-warning">Warning</button>
<button type="button" class="btn btn-outline-info">Info</button>
<button type="button" class="btn btn-outline-light">Light</button>
<button type="button" class="btn btn-outline-dark">Dark</button>
Sizes
Fancy larger or smaller buttons? Add .btn-lg or .btn-sm for additional sizes.
.btn-lg
<button type="button" class="btn btn-primary btn-lg">Large button</button>
<button type="button" class="btn btn-secondary btn-lg">Large button</button>
.btn-sm
<button type="button" class="btn btn-primary btn-sm">Small button</button>
<button type="button" class="btn btn-secondary btn-sm">Small button</button>
.btn-block
![](https://rathorji.in/post-media/d0836eedc9fecb9a0a9240fb6b69869a/2ba43c872d264a37b425de64b71902ae.jpg)
<button type="button" class="btn btn-primary btn-lg btn-block">Block level button</button>
Download source code
Are you facing problems in understanding this article? download source code now