This is specific to the shopping cart being used as there would most likely be a converter directly linked to the shopping cart available externally.
The reason for a converter would be due to PayFast only working with ZAR and not providing a currency conversion service. This would need to be handled before the amount is sent to PayFast (i.e. before redirect to our payment gateway).
Should your site require you to have a currency converter, please look into the plugins provided with your platform.
Please be advised, the below are purely examples and not endorsed by PayFast. Please do the appropriate research on the currency converter you require for your needs.
Shopify – You can look into one of these for Shopify https://www.delightchat.io/best-shopify-apps/currency-converter
WordPress – https://www.isitwp.com/best-wordpress-currency-exchange-plugins/
WooCommerce - https://woocommerce.com/document/currency-converter-widget/