{"id":41615,"date":"2015-02-11T01:19:53","date_gmt":"2015-02-11T06:19:53","guid":{"rendered":"http:\/\/www.templatemonster.com\/help\/?p=41615"},"modified":"2016-04-12T09:58:20","modified_gmt":"2016-04-12T13:58:20","slug":"woocommerce-how-change-amount-of-products-per-row","status":"publish","type":"post","link":"https:\/\/www.templatemonster.com\/help\/woocommerce-how-change-amount-of-products-per-row.html","title":{"rendered":"WooCommerce. How change amount of products per row"},"content":{"rendered":"<p>\r\n<p>Hello, this tutorial shows how to change the number of product columns in your WooCommerce store.<\/p>\r\n<p><a href=\"http:\/\/www.youtube.com\/watch?v=u9dsiR8QMjY?width=1280&amp;height=720\" rel=\"prettyPhoto\">WooCommerce. How change amount of products per row <\/a><\/p>\r\n<p>You can set the products on your <strong>Homepage<\/strong> using  a shortcode. You can also see products displaying on the <strong>Category<\/strong> page or the main <strong>Shop<\/strong> page.<\/p>\r\n<p>In order to change the number of columns on your <strong>Homepage<\/strong>, you should follow the steps listed below:<\/p>\r\n<ol>\r\n<li>\r\n<p>Open your WordPress admin panel and navigate to <strong>Pages > All Pages<\/strong>;<\/p>\r\n<\/li>\r\n<li>\r\n<p>Select <strong>Home<\/strong> from the list of the available pages: <\/p>\r\n<p><a href=\"\/help\/wp-content\/uploads\/2014\/12\/WooCommerce.-How-change-the-amount-of-products-per-row-1.jpg.jpg\"><img loading=\"lazy\" src=\"\/help\/wp-content\/uploads\/2014\/12\/WooCommerce.-How-change-the-amount-of-products-per-row-1.jpg-300x168.jpg\" alt=\"WooCommerce. How change the amount of products per row-1.jpg\" width=\"300\" height=\"168\" class=\"aligncenter size-medium wp-image-41621\" srcset=\"https:\/\/www.templatemonster.com\/help\/wp-content\/uploads\/2014\/12\/WooCommerce.-How-change-the-amount-of-products-per-row-1.jpg-300x168.jpg 300w, https:\/\/www.templatemonster.com\/help\/wp-content\/uploads\/2014\/12\/WooCommerce.-How-change-the-amount-of-products-per-row-1.jpg-150x84.jpg 150w, https:\/\/www.templatemonster.com\/help\/wp-content\/uploads\/2014\/12\/WooCommerce.-How-change-the-amount-of-products-per-row-1.jpg-1024x576.jpg 1024w, https:\/\/www.templatemonster.com\/help\/wp-content\/uploads\/2014\/12\/WooCommerce.-How-change-the-amount-of-products-per-row-1.jpg.jpg 1280w\" sizes=\"(max-width: 300px) 100vw, 300px\" \/><\/a>\r\n<\/li>\r\n<li>\r\n<p>Scroll down the page content to find a corresponding shortcode and edit the number of columns:<\/p>\r\n<p><a href=\"\/help\/wp-content\/uploads\/2014\/12\/WooCommerce.-How-change-the-amount-of-products-per-row-2.jpg.jpg\"><img loading=\"lazy\" src=\"\/help\/wp-content\/uploads\/2014\/12\/WooCommerce.-How-change-the-amount-of-products-per-row-2.jpg-300x168.jpg\" alt=\"WooCommerce. How change the amount of products per row-2.jpg\" width=\"300\" height=\"168\" class=\"aligncenter size-medium wp-image-41620\" srcset=\"https:\/\/www.templatemonster.com\/help\/wp-content\/uploads\/2014\/12\/WooCommerce.-How-change-the-amount-of-products-per-row-2.jpg-300x168.jpg 300w, https:\/\/www.templatemonster.com\/help\/wp-content\/uploads\/2014\/12\/WooCommerce.-How-change-the-amount-of-products-per-row-2.jpg-150x84.jpg 150w, https:\/\/www.templatemonster.com\/help\/wp-content\/uploads\/2014\/12\/WooCommerce.-How-change-the-amount-of-products-per-row-2.jpg-1024x576.jpg 1024w, https:\/\/www.templatemonster.com\/help\/wp-content\/uploads\/2014\/12\/WooCommerce.-How-change-the-amount-of-products-per-row-2.jpg.jpg 1280w\" sizes=\"(max-width: 300px) 100vw, 300px\" \/><\/a>\r\n<\/li>\r\n<li>\r\n<p>Save the changes and check your <strong> Homepage<\/strong>.<\/p>\r\n<\/li>\r\n<\/ol>\r\n<p>In case you increased\/decreased the number of columns and the page layout looks broken, please follow these steps:<\/p>\r\n<ol>\r\n<li>\r\n<p>Connect to your FTP and follow this path <strong>wp-content\/theme\/themeXXXXX\/style.less<\/strong>:<\/p>\r\n<p><a href=\"\/help\/wp-content\/uploads\/2014\/12\/WooCommerce.-How-change-the-amount-of-products-per-row-3.jpg\"><img loading=\"lazy\" src=\"\/help\/wp-content\/uploads\/2014\/12\/WooCommerce.-How-change-the-amount-of-products-per-row-3-300x168.jpg\" alt=\"WooCommerce. How change the amount of products per row-3\" width=\"300\" height=\"168\" class=\"aligncenter size-medium wp-image-41619\" srcset=\"https:\/\/www.templatemonster.com\/help\/wp-content\/uploads\/2014\/12\/WooCommerce.-How-change-the-amount-of-products-per-row-3-300x168.jpg 300w, https:\/\/www.templatemonster.com\/help\/wp-content\/uploads\/2014\/12\/WooCommerce.-How-change-the-amount-of-products-per-row-3-150x84.jpg 150w, https:\/\/www.templatemonster.com\/help\/wp-content\/uploads\/2014\/12\/WooCommerce.-How-change-the-amount-of-products-per-row-3-1024x576.jpg 1024w, https:\/\/www.templatemonster.com\/help\/wp-content\/uploads\/2014\/12\/WooCommerce.-How-change-the-amount-of-products-per-row-3.jpg 1280w\" sizes=\"(max-width: 300px) 100vw, 300px\" \/><\/a>\r\n<\/li>\r\n<li>\r\n<p>Open the <strong>style.less<\/strong> file with the code editor and look for the responsive CSS code for the product columns layout:<\/p>\r\n<pre class=\"brush:css\">\r\n\t\t\t\t\t@media (min-width: 1200px) {\r\n\t\t\t\t\t\twidth: 270px;\r\n\t\t\t\t\t\tmargin-left: 30px;\r\n\t\t\t\t\t}\r\n\t\t\t\t\t@media (min-width: 768px) and (max-width: 979px) {\r\n\t\t\t\t\t\twidth: 166px;\r\n\t\t\t\t\t\tmargin-left: 20px;\r\n\t\t\t\t\t\tpadding-bottom: 10px;\r\n\t\t\t\t\t}\r\n\t\t\t\t\t@media (max-width: 767px){\r\n\t\t\t\t\t\twidth: 31%;\r\n\t\t\t\t\t\tmargin-left: 2%;\r\n\r\n\t\t\t\t\t}\r\n\t\t\t\t\t@media (max-width: 650px){\r\n\t\t\t\t\t\tpadding-bottom: 10px;\r\n\t\t\t\t\t}\r\n\t\t\t\t\t@media (max-width:480px){\r\n\t\t\t\t\t\twidth: 47%;\r\n\t\t\t\t\t\tmargin: 0 1% 20px;\r\n\t\t\t\t\t\tdisplay: inline-block;\r\n\t\t\t\t\t\tvertical-align: top;\r\n\t\t\t\t\t\tfloat: none;\r\n\t\t\t\t\t}\r\n\t\t\t\t\t@media (max-width:320px){\r\n\t\t\t\t\t\twidth: 100%;\r\n\t\t\t\t\t\tmargin-left: 0;\r\n\t\t\t\t\t\tdisplay: block;\r\n\t\t\t\t\t}\r\n<\/pre>\r\n<\/li>\r\n<li>\r\n<p>You can change the width for the different device layouts to make the columns fit:<\/p>\r\n<p><a href=\"\/help\/wp-content\/uploads\/2014\/12\/WooCommerce.-How-change-the-amount-of-products-per-row-4.jpg\"><img loading=\"lazy\" src=\"\/help\/wp-content\/uploads\/2014\/12\/WooCommerce.-How-change-the-amount-of-products-per-row-4-300x168.jpg\" alt=\"WooCommerce. How change the amount of products per row-4\" width=\"300\" height=\"168\" class=\"aligncenter size-medium wp-image-41618\" srcset=\"https:\/\/www.templatemonster.com\/help\/wp-content\/uploads\/2014\/12\/WooCommerce.-How-change-the-amount-of-products-per-row-4-300x168.jpg 300w, https:\/\/www.templatemonster.com\/help\/wp-content\/uploads\/2014\/12\/WooCommerce.-How-change-the-amount-of-products-per-row-4-150x84.jpg 150w, https:\/\/www.templatemonster.com\/help\/wp-content\/uploads\/2014\/12\/WooCommerce.-How-change-the-amount-of-products-per-row-4-1024x576.jpg 1024w, https:\/\/www.templatemonster.com\/help\/wp-content\/uploads\/2014\/12\/WooCommerce.-How-change-the-amount-of-products-per-row-4.jpg 1280w\" sizes=\"(max-width: 300px) 100vw, 300px\" \/><\/a>\r\n<\/li>\r\n<li>\r\n<p>Save the changes and re-upload the file to your server.<\/p>\r\n<\/li>\r\n<\/ol>\r\n<p>In order to change the number of columns on the <strong>Category<\/strong> page, please follow these steps:<\/p>\r\n<ol>\r\n<li>\r\n<p>Open your WordPress admin panel and navigate to <strong>Appearance > Editor<\/strong>;<\/p>\r\n<\/li>\r\n<li>\r\n<p>Locate the file called  <strong>custom-function.php<\/strong> under your child theme:<\/p>\r\n<p><a href=\"\/help\/wp-content\/uploads\/2014\/12\/WooCommerce.-How-change-the-amount-of-products-per-row-5.jpg\"><img loading=\"lazy\" src=\"\/help\/wp-content\/uploads\/2014\/12\/WooCommerce.-How-change-the-amount-of-products-per-row-5-300x168.jpg\" alt=\"WooCommerce. How change the amount of products per row-5\" width=\"300\" height=\"168\" class=\"aligncenter size-medium wp-image-41617\" srcset=\"https:\/\/www.templatemonster.com\/help\/wp-content\/uploads\/2014\/12\/WooCommerce.-How-change-the-amount-of-products-per-row-5-300x168.jpg 300w, https:\/\/www.templatemonster.com\/help\/wp-content\/uploads\/2014\/12\/WooCommerce.-How-change-the-amount-of-products-per-row-5-150x84.jpg 150w, https:\/\/www.templatemonster.com\/help\/wp-content\/uploads\/2014\/12\/WooCommerce.-How-change-the-amount-of-products-per-row-5-1024x576.jpg 1024w, https:\/\/www.templatemonster.com\/help\/wp-content\/uploads\/2014\/12\/WooCommerce.-How-change-the-amount-of-products-per-row-5.jpg 1280w\" sizes=\"(max-width: 300px) 100vw, 300px\" \/><\/a>\r\n<\/li>\r\n<li>\r\n<p>Press <strong>Ctrl+F<\/strong>  and look for the following text in the mentioned file: <strong>Change columns number<\/strong>;<\/p>\r\n<\/li>\r\n<li>\r\n<p>You will see the following part of the code, where you can edit the number of columns: <\/p>\r\n<pre class=\"brush:php\">\/\/ Change columns number\r\n\t\t\/\/ ---------------------\r\n\t\tadd_filter( 'loop_shop_columns', 'tm_product_columns', 5);\r\n\t\tfunction tm_product_columns($columns) {\r\n\t\t\tif ( is_shop() || is_product_category() || is_product_tag() ) {\r\n\t\t\t\t$columns = 3;\r\n\t\t\t\treturn $columns;\r\n\t\t\t}\r\n\t\t}\r\n<\/pre>\r\n<p><a href=\"\/help\/wp-content\/uploads\/2014\/12\/WooCommerce.-How-change-the-amount-of-products-per-row-6.jpg\"><img loading=\"lazy\" src=\"\/help\/wp-content\/uploads\/2014\/12\/WooCommerce.-How-change-the-amount-of-products-per-row-6-300x168.jpg\" alt=\"WooCommerce. How change the amount of products per row-6\" width=\"300\" height=\"168\" class=\"aligncenter size-medium wp-image-41616\" srcset=\"https:\/\/www.templatemonster.com\/help\/wp-content\/uploads\/2014\/12\/WooCommerce.-How-change-the-amount-of-products-per-row-6-300x168.jpg 300w, https:\/\/www.templatemonster.com\/help\/wp-content\/uploads\/2014\/12\/WooCommerce.-How-change-the-amount-of-products-per-row-6-150x84.jpg 150w, https:\/\/www.templatemonster.com\/help\/wp-content\/uploads\/2014\/12\/WooCommerce.-How-change-the-amount-of-products-per-row-6-1024x576.jpg 1024w, https:\/\/www.templatemonster.com\/help\/wp-content\/uploads\/2014\/12\/WooCommerce.-How-change-the-amount-of-products-per-row-6.jpg 1280w\" sizes=\"(max-width: 300px) 100vw, 300px\" \/><\/a>\r\n<\/li>\r\n<li>\r\n<p>Save your changes and check the website.<\/p>\r\n<\/li>\r\n<\/ol>\r\n<p>Feel free to check the detailed video tutorial below:<\/p>\r\n<p><a href=\"http:\/\/www.youtube.com\/watch?v=u9dsiR8QMjY?width=1280&amp;height=720\" rel=\"prettyPhoto\">WooCommerce. How change amount of products per row <\/a><\/p>\r\n<p><\/p>","protected":false},"excerpt":{"rendered":"<p>This tutorial shows how to change the number of product columns in your WooCommerce store<\/p>\n","protected":false},"author":64,"featured_media":43701,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":[],"categories":[1556],"tags":[656,668,542,1756,2418],"_links":{"self":[{"href":"https:\/\/www.templatemonster.com\/help\/wp-json\/wp\/v2\/posts\/41615"}],"collection":[{"href":"https:\/\/www.templatemonster.com\/help\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.templatemonster.com\/help\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.templatemonster.com\/help\/wp-json\/wp\/v2\/users\/64"}],"replies":[{"embeddable":true,"href":"https:\/\/www.templatemonster.com\/help\/wp-json\/wp\/v2\/comments?post=41615"}],"version-history":[{"count":0,"href":"https:\/\/www.templatemonster.com\/help\/wp-json\/wp\/v2\/posts\/41615\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.templatemonster.com\/help\/wp-json\/wp\/v2\/media\/43701"}],"wp:attachment":[{"href":"https:\/\/www.templatemonster.com\/help\/wp-json\/wp\/v2\/media?parent=41615"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.templatemonster.com\/help\/wp-json\/wp\/v2\/categories?post=41615"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.templatemonster.com\/help\/wp-json\/wp\/v2\/tags?post=41615"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}