Android Material Chip Margin Spacing in ChipGroup

If you add multiline Chip dynamically to ChipGroup until it expand to multiple rows, there is zero margin vertical margin.

Set app:chipSpacingVertical on ChipGroup to enable margin spacing.


NOTE: You can set app:chipSpacingHorizontal or app:chipSpacing as well.

NOTE: Strangely, default margin for static Chip defined in xml vs dynamic Chip added programatically is different. I am using

NOTE: Setting layoutParams on Chip doesn't work.

❤️ Is this article helpful?

Buy me a coffee ☕ or support my work via PayPal to keep this space 🖖 and ad-free.

Do send some 💖 to @d_luaz or share this article.

✨ By Desmond Lua

A dream boy who enjoys making apps, travelling and making youtube videos. Follow me on @d_luaz

👶 Apps I built

Travelopy - discover travel places in Malaysia, Singapore, Taiwan, Japan.