How to enable horizontal scroll in tab like Google Play?

TabLayout has a method setTabMode() which can be either MODE_FIXED (default) or MODE_SCROLLABLE which is what you need.

You can also define this in XML with app:tabMode="scrollable".


You can add this app:tabMode="scrollable" to your android.support.design.widget.TabLayout


If you added

app:tabMode="scrollable" 

like mentioned above and it,

shows the layout and you are not able to scroll

Then maybe you have put it at the top of the XML file and below it added matchh_parent (height/width) to the ViewPager. Because the viewpager is above the tab layout you will not be able to scroll. Add it at the bottom of the XML so another view does to overlap the tab layout.