Skip Navigation
March 1, 2023

Some plugins use URL arguments, and you may want to keep them when switching languages. Here’s how you can do that using WPML’s language switcher options.

You can preserve these URL arguments by going to WPMLLanguages and scrolling to the Language switcher options section. The arguments you want to preserve should be added as a comma-separated list.

Preserve URL arguments dialog box

Let’s consider the following example of using this feature. Suppose you add the following arguments: bar, foo.

You translate the “Hello world” post. In the front-end, open the “Hello world” post and add this at the end of the URL: ?bar=10&foo=100&lost=1000 (notice that we added the two arguments + the lost one).When you switch the language, the URL will end only with ?bar=10&foo=100.