I\'m using WooCommerce with the \"YITH WooCommerce Ajax Navigation\" plugin to filter brands. The result is a link that appears as https://example.com/products/racquet
It's a matter of adding a Rewrite Endpoint:
Adding an endpoint creates extra rewrite rules for each of the matching places specified by the provided bitmask. A new query var with the same name as the endpoint will also be created. The string following the endpoint definition supplies the value for this query var (e.g.
"/foo/bar/"becomes"?foo=bar").
Then, in the templates use it like:
$brand = get_query_var('brand') ? urldecode( get_query_var('brand') ) : 'Empty endpoint';
echo $brand;