Bootstrap 5 Input Examples

Ruth Jul 09, 2026

Bootstrap, a popular open-source CSS framework, has been a game-changer for web developers, offering a robust set of pre-designed components and styles. With the release of Bootstrap 5, the framework has introduced numerous improvements, including a revamped input component. Let's dive into an example of using Bootstrap 5's input component and explore its features.

an email form with two different types of letters and numbers on the top right hand corner
an email form with two different types of letters and numbers on the top right hand corner

Before we proceed, ensure you have included the Bootstrap 5 CDN in your project's HTML file. The latest version can be added with the following script tag:

Bootstrap Tutorial | Bootstrap Notes | Bootstrap 5
Bootstrap Tutorial | Bootstrap Notes | Bootstrap 5

```html ```

Basic Bootstrap 5 Input Example

Let's start with a simple input example using Bootstrap 5. We'll create a basic text input with a label and placeholder text.

Bootstrap Tutorial | Bootstrap Notes | Bootstrap 5
Bootstrap Tutorial | Bootstrap Notes | Bootstrap 5

Here's the HTML code for a basic Bootstrap 5 input:

```html

We'll never share your email with anyone else.
```

Form Control Sizes

Bootstrap Tutorial | Bootstrap Notes | Bootstrap 5
Bootstrap Tutorial | Bootstrap Notes | Bootstrap 5

Bootstrap 5 allows you to change the size of form controls using the `form-control-lg` or `form-control-sm` classes. Here's an example:

```html

```

Disabled Inputs

To create a disabled input, add the `disabled` attribute to the input element. Here's an example:

Bootstrap Tutorial | Bootstrap Notes | Bootstrap 5
Bootstrap Tutorial | Bootstrap Notes | Bootstrap 5

```html

```

Input Groups

Input groups combine form controls within a single element. They are useful for adding labels, buttons, or other elements to an input field.

Here's an example of an input group with a text input and a button:

Bootstrap Tutorial | Bootstrap Notes | Bootstrap 5
Bootstrap Tutorial | Bootstrap Notes | Bootstrap 5

```html

```

Input Group Sizes

Like form controls, input groups can also have different sizes. Here's an example:

Bootstrap Tutorial | Bootstrap Notes | Bootstrap 5
Bootstrap Tutorial | Bootstrap Notes | Bootstrap 5
Bootstrap Tutorial | Bootstrap Notes | Bootstrap 5
Bootstrap Tutorial | Bootstrap Notes | Bootstrap 5
Best Free Bootstrap Login Forms ยป CSS Author
Best Free Bootstrap Login Forms ยป CSS Author
A Beginner's Guide to the Latest Bootstrap 5 Utilities
A Beginner's Guide to the Latest Bootstrap 5 Utilities
Bootstrap Tutorial | Bootstrap Notes | Bootstrap 5
Bootstrap Tutorial | Bootstrap Notes | Bootstrap 5
Bootstrap Tutorial | Bootstrap Notes | Bootstrap 5
Bootstrap Tutorial | Bootstrap Notes | Bootstrap 5
HTML Form Validation with Bootstrap
HTML Form Validation with Bootstrap
a set of colorful buttons with different shapes and sizes for web pages, presentations or presentation
a set of colorful buttons with different shapes and sizes for web pages, presentations or presentation
Bootstrap 4 cheat sheet
Bootstrap 4 cheat sheet
BOOTSTRAP INPUT FORM (2020) | HOW TO MAKE FORM IN BOOTSTRAP
BOOTSTRAP INPUT FORM (2020) | HOW TO MAKE FORM IN BOOTSTRAP
Simple To Do List Using Bootstrap 5 โ€” CodeHim
Simple To Do List Using Bootstrap 5 โ€” CodeHim
Free 22+ HTML5 Signup & Registration Forms - HTML, CSS
Free 22+ HTML5 Signup & Registration Forms - HTML, CSS
๐Ÿ“ Create Text Input Forms and Submit Button in HTML
๐Ÿ“ Create Text Input Forms and Submit Button in HTML
Bootstrap Forms
Bootstrap Forms
the different types of font and numbers
the different types of font and numbers
AdminKit PRO - Bootstrap 5 Admin Template
AdminKit PRO - Bootstrap 5 Admin Template
Add Bootstrap Glyphicon to Input Box
Add Bootstrap Glyphicon to Input Box
Bootstrap 5 tutorial - Learn how to get started without jQuery - Themesberg Blog
Bootstrap 5 tutorial - Learn how to get started without jQuery - Themesberg Blog
Wizard
Wizard
Bootstrap 5 Classes List Cheat Sheet
Bootstrap 5 Classes List Cheat Sheet

```html

Large
Small
```

Bootstrap 5's input component offers numerous customization options, allowing you to create responsive and visually appealing forms. Explore the official Bootstrap 5 documentation for more examples and advanced usage.