In this post i will explain What to Expect from Yii 2.0. The latest version of Yii 2 is 2.0.0, released on October 12, 2014. It’s aimed to become a state-of-the-art of the new generation of PHP framework. Yii 2.0 is not compatible with 1.1. Yii 2.0.0 is a complete rewrite of its previous version Yii 1.1 which is one of the most popular PHP frameworks.




The usage of namespaces and traits upped the requirements to PHP 5.4. Additionally, you’ll need the mb_string, PDO and intl extensions when you start developing. This should not be a problem if you run your own server, but might be if you’re on a shared environment. Of course, in time, that issue will disappear.

Feathures :

  • Quick prototyping with support for common APIs for ActiveRecord;
  • Response format negotiation (supporting JSON and XML by default);
  • Customizable object serialization with support for selectable output fields;
  • Proper formatting of collection data and validation errors;
  • Efficient routing with proper HTTP verb check;
  • Support for OPTIONS and HEAD verbs;
  • Authentication;
  • Authorization;
  • Support for HATEOAS;
  • HTTP Caching;
  • Rate limiting.

Install via Composer

This is the preferred way of installing Yii 2.0. If you do not have Composer yet, you may install it by following the instructions here

After installing Composer, run the following command to install the Composer Asset Plugin:

To install the basic application template, run the command below:

To install the advanced application template, run the command below:

Install from an Archive File

Download one of the following archive files, and then extract it to a Web-accessible folder:


The documentation quality for Yii 2.0 improved from Yii 1.1. I had a hard time figuring stuff out when I started with Yii 1.1 a few years ago and I feel the documentation is more extensive than before.

Have you looked at Yii 2.0 already or perhaps even built something with it already? Please tell us what you came across. I would love to know your experiences!