By default Matomo (Piwik) uses the browser language to determine location. To improve accuracy of country detection (and enable Region and City tracking), go to Matomo > Administration > Geo Location. Then, you can select the appropriate solution for your install. These include the PHP DB-IP (default), the PHP GeoIP library from Maxmind (it can provide better accuracy than DB-IP) or a server side solutions such as GeoIP Apache or GeoIP PECL modules (all solutions will also require a geolocation database such as the Lite databases from DB-IP). Learn more about Visitors geo location in Matomo.

Previous FAQ: Setting up accurate visitors geolocation