When you add a regular link to a page or a post, WordPress saves the URL of that page as the link. This means, if the URL changes, the link is broken.

WordPress makes it all too easy to change page addresses, causing all incoming links to go broke (404 error). Here are a few ways to do that:

  • Change the page’s parent
  • Change the slug
  • Change the site’s permlink structure

WPML prevents changes in URLs from breaking incoming links. When you create a link, WPML automatically makes it Sticky. Instead of storing the URL of that page (at the time the link was created), it stores the page number. This can never change, no matter what you do.

Then, when the page is displayed, WPML inserts the permlink of the page you’re linking to. Whenever the URL changes all pages linking to it update immediately and will link to the correct address.

This screen shot shows how internal links look like in the database, once Sticky links are enabled:

Links turned Sticky by WPML

Links turned Sticky by WPML

Your users will never see these “strange” links. Instead, WPML will replace them with the current permlinks when displaying the pages.

Sticky links controls

Once you enable the Sticky Links module, you can control what strings it handles. Go to WPML->Sticky links.

Sticky Links before processing

Sticky Links before processing

By default, WPML will turn all links in post body to sticky. You can also turn links in widgets and strings to sticky.

WPML will let you batch replace all regular links to sticky links. It will also report any existing broken links and help fix them.

If you’ve enabled Sticky Links after creating some content, links in that existing content are not immediately turned into Sticky.

The Sticky Links admin screen tells you how much content may include normal (not Sticky) links. WPML can scan that content and convert all links to Sticky. Click on the Scan button to do that.

You can always return your links to regular (not Sticky) by clicking on ‘Revert sticky urls to permalinks