Last updated on January 21st, 2019 at 10:53 am

In this tip i will explain how to implement zoom effect on ImageView Android. To get this thing done we can use this library you can find on GitHub this library is very simple and useful. You can use this library on both activity or fragment.

Implementation of Zoom effect on ImageView

Step 1. Add dependencies on your app build.gradle

implementation 'com.github.chrisbanes:PhotoView:2.0.0'

Step 2. Now we can Dynamically add image in our activity class


LinearLayout layout = (LinearLayout) findViewById(;
PhotoView photoView = new PhotoView(getApplicationContext());

This is just for help for beginners to implement zoom on ImageView you can follow this link to get complete info.

Done 🙂