Get Country name from Country id Magento 2.

You can get full country name from country id using Magento 2.

You need to instantiate CountryFactory in your class __construct() method to get the country full name.

The class responsible to get name is Magento\Directory\Model\Country.

call from template or other class,
$countryId = “IN”; // or IND
echo $countryName = $this->getCountryName($countryId);

For Country Id “US” or “USA” => United States.