How to Make the Divi Gallery Have 5 or More Columns
The Divi Gallery module has 4 columns by default (in the grid format). In today’s post I’m going to guide you on how you can make it have 5, 6 or more columns. Or, less than 4, for example 3 as well.
First of all, just create a Divi section, add a row and insert the Gallery module. Then in the design settings of the row choose “Use Custom Gutter Width: YES” and select 1 for “Gutter Width”.
After that in the Gallery module’s settings choose “Layout: Grid”, “Show Title and Caption: NO” and “Show Pagination: NO”. And upload your images for this gallery.
Then the most important thing to do is to add the following custom CSS code to the gallery module advanced settings. Add it to the “Gallery Item” field:
margin: 0 !important; width: 20% !important; clear: none !important;
This CSS code will make your gallery have 5 columns. If you want e.g. 6 columns, put 16.66% instead of 20%. The key here is to divide 100% by the number of columns that you want your gallery to have. For example, if you need just 3 columns, use 33.33%. And so on.
Good luck with creating your gallery!
For more Divi tutorials like this one, you can subscribe to my newsletter.