To turn the feature on, click on Settings in the upper right corner of Gmail, scroll down and choose whether you want to be notified of chat messages, all emails, or just ‘Important’ ones (based on your Priority Inbox).
Google hopes the new feature will keep you from switching back and forth to Gmail to check for new messages. Of course there are already plenty of extensions that can do the same, but this update might make things just a little bit easier.
The company also recently unveiled a new unread message favicon in Gmail Labs if you are looking for something a little more subtle. The feature essentially lets you see how many unread messages are in your inbox with a quick glance at the tab's icon -- as opposed to reading it from the tab title. This is useful when you have many tabs open cutting off the unread e-mail message number from the title, or if you like to keep Gmail as an always open pinned tab.