Google is planning to add a data encryption feature to its Android L operating system, which is set debut next month.

The automatic data encryption will ensure that data such as photos, videos, messages, and contact lists are accessible only after unlocking the smartphone with a password.

This means law enforcement agencies will not be able to collect evidencs from smartphones unless the users share their password.

The automatic encryption will also make government snooping more difficult.

Google has been offering optional encryption to selected devices since 2011, enabling users to manually turn on the feature to add an additional level of protection.

The Washington Post has quoted Google spokesperson Niki Christoff as saying: "For over three years Android has offered encryption, and keys are not stored off of the device, so they cannot be shared with law enforcement.

"As part of our next Android release, encryption will be enabled by default out of the box, so you won’t even have to think about turning it on."

The new automatic encryption method is similar to that adopted by Apple for iOS 8.

Reports suggest that the new security update will take more time to roll out, as Android updates are carrier dependent. Deployment of the new encryption method could be delayed by up to a year after the launch of the new OS.