PHPackages                             yiisoft/yii2-bootstrap5 - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Framework](/categories/framework)
4. /
5. yiisoft/yii2-bootstrap5

ActiveYii2-extension[Framework](/categories/framework)

yiisoft/yii2-bootstrap5
=======================

The Twitter Bootstrap v5 extension for the Yii framework

2.0.51(5mo ago)661.4M—3.6%45[6 issues](https://github.com/yiisoft/yii2-bootstrap5/issues)[2 PRs](https://github.com/yiisoft/yii2-bootstrap5/pulls)20BSD-3-ClausePHPPHP &gt;=7.3CI passing

Since Aug 11Pushed 2mo ago13 watchersCompare

[ Source](https://github.com/yiisoft/yii2-bootstrap5)[ Packagist](https://packagist.org/packages/yiisoft/yii2-bootstrap5)[ GitHub Sponsors](https://github.com/yiisoft)[ Fund](https://opencollective.com/yiisoft)[ RSS](/packages/yiisoft-yii2-bootstrap5/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (3)Dependencies (6)Versions (8)Used By (20)

    ![Yii Framework](https://camo.githubusercontent.com/cc75562bca6e54e98046e4fb187ef8d96c997a8f31c6f4d2f6ed0c816413b47a/68747470733a2f2f7777772e7969696672616d65776f726b2e636f6d2f696d6167652f7969695f6c6f676f5f6c696768742e737667)

Twitter Bootstrap 5 Extension for Yii 2
=======================================

[](#twitter-bootstrap-5-extension-for-yii-2)

This is the Twitter Bootstrap extension for [Yii framework 2.0](https://www.yiiframework.com). It encapsulates [Bootstrap 5](https://getbootstrap.com/) components and plugins in terms of Yii widgets, and thus makes using Bootstrap components/plugins in Yii applications extremely easy.

For license information check the [LICENSE](LICENSE.md)-file.

Documentation is at [docs/guide/README.md](docs/guide/README.md).

[![Latest Stable Version](https://camo.githubusercontent.com/fdffca231f2527a011ca7fe6841c16ab2cacad145b5516318ede1fd2c832de5c/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f796969736f66742f796969322d626f6f747374726170352e7376673f7374796c653d666f722d7468652d6261646765266c6162656c3d537461626c65266c6f676f3d7061636b6167697374)](https://packagist.org/packages/yiisoft/yii2-bootstrap5)[![Total Downloads](https://camo.githubusercontent.com/a90945deab98e80cf6af36e7c42d916330ffe9c3148d645cb46f586a6f26f3ed/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f796969736f66742f796969322d626f6f747374726170352e7376673f7374796c653d666f722d7468652d6261646765266c6162656c3d446f776e6c6f616473)](https://packagist.org/packages/yiisoft/yii2-bootstrap5)[![build](https://camo.githubusercontent.com/64fd99673b303b9650570ad2341eade5ecc034c43484c5862079b937ca43ae8a/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f616374696f6e732f776f726b666c6f772f7374617475732f796969736f66742f796969322d626f6f747374726170352f6275696c642e796d6c3f7374796c653d666f722d7468652d6261646765266c6f676f3d676974687562266c6162656c3d4275696c64)](https://github.com/yiisoft/yii2-bootstrap5/actions?query=workflow%3Abuild)[![codecov](https://camo.githubusercontent.com/25eed51b1721a6a32259c2caf7d7c93cf3f358bf2cd0bf7afde17541d204acbf/68747470733a2f2f696d672e736869656c64732e696f2f636f6465636f762f632f6769746875622f796969736f66742f796969322d626f6f747374726170352e7376673f7374796c653d666f722d7468652d6261646765266c6f676f3d636f6465636f76266c6f676f436f6c6f723d7768697465266c6162656c3d436f6465636f76)](https://codecov.io/gh/yiisoft/yii2-bootstrap5)[![Static Analysis](https://camo.githubusercontent.com/dd3bd450b75f91dec610745c67eb7ee9291a4bdcd7160df29813dff9b91f2fed/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f616374696f6e732f776f726b666c6f772f7374617475732f796969736f66742f796969322d626f6f747374726170352f7374617469632e796d6c3f7374796c653d666f722d7468652d6261646765266c6162656c3d537461746963)](https://github.com/yiisoft/yii2-bootstrap5/actions/workflows/static.yml)

Installation
------------

[](#installation)

Important

- The minimum required [PHP](https://www.php.net/) version is PHP `7.4`.
- It works best with PHP `8`.

The preferred way to install this extension is through [composer](https://getcomposer.org/download/).

Either run

```
php composer.phar require --prefer-dist yiisoft/yii2-bootstrap5

```

or add

```
"yiisoft/yii2-bootstrap5": "*"

```

to the require section of your `composer.json` file.

Translations
------------

[](#translations)

The i18n configuration will be automatically added to your application configuration via bootstrapping process.

Usage
-----

[](#usage)

For example, the following single line of code in a view file would render a Bootstrap Progress plugin:

```
