Auto Currency Switcher 2: Magento 2 Extension [FREE]

Auto Currency Switcher 2 is a currency switcher extension for Magento 2 which automatically switches store currency based on visitor’s IP address.

Auto Currency Switcher 2 extension tracks visitor’s IP address and automatically changes the store currency to the visitor’s location currency. Visitor can switch to his/her desired currency at any time.

This extension uses Webnet77’s Ip2Country IP Address databases for IP Address lookup.

No extra configuration settings to be made. Just install the module in your multi-currency Magento shop and the module will work on the fly.

But remember that, you should first setup/enable multiple currency on your shop.

Enable Multiple Currency on your Magento 2 store

– Login to Magento 2 Admin
– Go to STORES -> Configuration -> GENERAL -> Currency Setup -> Currency Options
– In Allowed Currencies box, select the currencies that you want to enable on your site/store
– Now, go to STORES -> Currency Rates
– Import currency rates by clicking the Import button, Or add the rates manually
– Then, click the Save Currency Rates button

Testing this extension

Here are the steps to test if this module is working or not.

– First of all, as mentioned above, you have to enable multiple currencies in your shop.

– Open app/code/Chapagain/AutoCurrency/Helper/Data.php

– Edit the following function. You can just return the IP Address instead of $_SERVER[‘REMOTE_ADDR’]. In the below code, IP addresses of some countries are given. You can also get IPs of different countries from this website.


/**
 * Get IP Address
 *
 * @return string
 */
public function getIpAddress() 
{		
	// http://www.xroxy.com/proxylist.php?country=GB&sort=ip
	//return '128.199.105.86';	// GB/UK
	//return '104.131.166.160';	// US
	//return '146.185.155.141';	// NL
	//return '103.252.194.100';	// IN
	//return '203.78.162.156';	// NP
	return $_SERVER['REMOTE_ADDR'];
}

– Now, go to any product listing page.

– You should be able to see product price in the currency of the country’s IP which you have set in the above function.

Please note that sometimes this extension doesn’t perform due to browser cache. If you find this module not working then try clearing your browser cache. Or, try opening your website in another browser or in private/incognito mode.

Download FREE Auto Currency Extension for Magento 2

Thanks.