Reading // Return the number of products you wanna show per page. $cols = 12; return $cols; } // Change number or related products on product page function woo_related_products_limit() { global $product; $args['posts_per_page'] = 3; return $args; } add_filter( 'woocommerce_output_related_products_args', 'new_shop_related_products_args' ); function new_shop_related_products_args( $args ) { $args['posts_per_page'] = 3; // 4 related products $args['columns'] = 3; // arranged in 2 columns return $args; } //Before content if ( ! function_exists( 'new_shop_before_content' ) ) { /** * Before Content * Wraps all WooCommerce content in wrappers which match the theme markup * * @since 1.0.0 * @return void */ function new_shop_before_content() { ?>