Skip Navigation
Updated
November 23, 2023

Many countries share the same official language. WPML provides flags that link languages with countries where they are commonly spoken. If the provided flags don’t represent the country you wish to target, you can upload your own custom flag.

WPML comes with a built-in language switcher which lets you choose where to display it and how it should look. This includes the option to display flags for available languages.

For each pre-configured language, WPML comes with a built-in, default country flag. However, you may want to represent the languages on your site with different flags than the ones WPML provides.

Why You May Want to Change Flags in the Language Switcher 

Flags can add a unique touch to your language switcher and improve the user experience. If you localize your site for individual countries—by offering different shipping methods, for instance— flags make it easy for your site’s visitors to know which option to shop in.

However, flags can also cause confusion or even offend your site’s visitors. Depending on the languages you add to your site and the region you’re targeting, here are some factors to consider:

  • Flags represent a country, while a language may be spoken in several countries
  • Flags can trigger political or cultural sensitivities
  • While rare, countries can change flags
  • Some of your site’s visitors may not recognize certain flags

Take the Spanish language as an example. By default, WPML uses the flag of Spain to represent the Spanish language. Spanish is also spoken in numerous other countries including Argentina, Colombia, Peru and Venezuela. You can also find a large number of Spanish speakers in the United States and Puerto Rico.

Spanish is an example of a language spoken in many countries

If your site targets a Spanish-speaking audience in any South American country, using the Spanish flag may not be the best choice for your users. In such scenarios, you can:

  • List languages using their locale format and spelling. For example, Español instead of Spanish.
  • Display both the native language name and the one translated into your site’s default language, for example Español (Spanish).
  • Change the default flag and upload a custom flag.

How to Add a Custom Flag with WPML

To add a custom flag to your site:

  1. Go to WPML → Languages and click Edit Languages.  
Clicking on Edit Languages
  1. Next to the language you want to change the flag for, select the Custom flag option. Then, click Choose file and upload your flag as a PNG, JPG, GIF, or SVG file. 
Uploading a custom flag

After saving the changes, you should see the flag you uploaded in your language switcher.

Learn more about using custom flags and custom flag requirements in WPML.