Skip Navigation

This thread is resolved. Here is a description of the problem and solution.

The client was experiencing a 404 error on the Portuguese homepage of their website after translation. Additionally, the header and footer were not visible on the translated pages.

1. We identified a plugin conflict causing an infinite redirect and disabled the 'Redirect 404 to Homepage' plugin to resolve the initial access issue.
2. We discovered that the 'Edibbee' page, set as the front page, lacked translations in Portuguese and Spanish. We recommended translating this page to resolve the 404 errors.
3. For the URL structure, the language code 'pt-pt' is used as it is set in WPML -> Languages -> Edit Languages. We suggested creating a custom language for a different URL code if desired.
4. We addressed template translation issues by directing the client to for guidance on translating Elementor templates.
5. We increased the WordPress memory limit from 40MB to match the PHP memory limit of 2GB, which resolved issues with saving translations.

If this solution does not apply to your situation, or if it seems outdated, we recommend opening a new support ticket. We also advise checking related known issues at, verifying the version of the permanent fix, and confirming that you have installed the latest versions of themes and plugins. For further assistance, please visit our support forum at

This is the technical support forum for WPML - the multilingual WordPress plugin.

Everyone can read, but only WPML clients can post here. WPML team is replying on the forum 6 days per week, 22 hours per day.

This topic contains 9 replies, has 2 voices.

Last updated by Mateus Getulio 3 weeks ago.

Assisted by: Mateus Getulio.

Author Posts
May 27, 2024 at 3:18 pm #15674933


Tell us what you are trying to do?
I am translating my site to other languages. The PT homepage gives error hidden link. How can this be fixed. And want to confrirm 1 thing, if I translate it to other language the link should be [website name].com/pt or [website name].com/pt-pt?
Which one is correct?

What is the link to your site?
hidden link

May 27, 2024 at 7:45 pm #15675714

Mateus Getulio

Languages: English (English ) Portuguese (Brazil) (Português )

Timezone: America/Sao_Paulo (GMT-03:00)


Thanks for contacting us.

Can you please test minimal, using a default theme(if applicable) and with all non-WPML and essentials plugins disabled to see if the error persists. If possible make a backup of the site before doing it or test on a staging copy.

Also, so that we can take a better look at this, could you please attach the Debug info?

You can see how to retrieve and paste it here:

In summary, these are the steps that you need to take in order to retrieve it:

- Go to WPML > Support > Debug Information
- Copy the Debug Information from there.
- Find the “Additional Data” section below this chat.
- Click on the “Debug Info” item to expand it.

I'm enabling the Debug Info template for your next reply.

Looking forward to helping you resolve this issue.

May 28, 2024 at 6:03 am #15676251


FYI I cannot take backup or there isn't any beta site. We have to do the changes here only. Please let me know if the debug information helps provide the solution.

May 28, 2024 at 6:25 am #15676273


Also the header and footer are not visible.

May 28, 2024 at 1:16 pm #15678744

Mateus Getulio

Languages: English (English ) Portuguese (Brazil) (Português )

Timezone: America/Sao_Paulo (GMT-03:00)


Thank you for sharing the debug info.

I would like to request temporary access (wp-admin and FTP) to your site to take better look at the issue. You will find the needed fields for this below the comment area when you log in to leave your next reply. The information you will enter is private which means only you and I can see and have access to it.

Our Debugging Procedures

I will be checking various settings in the backend to see if the issue can be resolved. Although I won't be making changes that affect the live site, it is still good practice to backup the site before providing us access. In the event that we do need to debug the site further, I will duplicate the site and work in a separate, local development environment to avoid affecting the live site.

Privacy and Security Policy

We have strict policies regarding privacy and access to your information. Please see:


- Please make a backup of site files and database before providing us access.
- If you do not see the wp-admin/FTP fields this means your post & website login details will be made PUBLIC. DO NOT post your website details unless you see the required wp-admin/FTP fields. If you do not, please ask me to enable the private box. The private box looks like this: hidden link

Please, let me know if you need any additional details. Have a nice day.

May 28, 2024 at 5:51 pm #15680184

Mateus Getulio

Languages: English (English ) Portuguese (Brazil) (Português )

Timezone: America/Sao_Paulo (GMT-03:00)

Hello there,

Thank you for sharing the access to the site. I'll try to address your concerns, please let me know if I miss something.

1) The home page in Portuguese and Spanish was getting an infinite redirect due to a conflict with a plugin 'Redirect 404 to Homepage'. After I disable it, both languages are showing a 404 not found error.

2) The 404 not found error is happening because the page that is set up as the front page as the moment: 'Edibbee' doesn't have a translation. You can translate it to Portuguese and Spanish and it should start working properly.

3) Regarding the language in the URL, it will show up as pt-pt because it is the language code set up in WPML -> Languages -> Edit Languages. For default languages, you can't change it. But if you want to use a different language code(it is where WPML gets the info to display in the URL) you could create a custom language and set the desired language code and flag for example.

4) I checked and it looks like the templates are not translated yet, can you please try the steps outlined here to get them translated and see if it fixes the issue?

Thank you, please let us know

May 29, 2024 at 4:38 am #15681634


Hello there,

1. But the PT homepage is already translated so idealy it should not give 404 error. And only 8 Pages are shown in Portuguese but the rest of the pages are also translated then it should show but it is not showing.

2. How to do it?

3. Okay no problem. pt-pt is fine.

4. PFA. No templates aree found.

Please reply asap.

May 29, 2024 at 1:08 pm #15683970

Mateus Getulio

Languages: English (English ) Portuguese (Brazil) (Português )

Timezone: America/Sao_Paulo (GMT-03:00)

Hello there,

I checked it and it looks like the current page set as the home page has the 'add translation' icon available, indicating that it might be missing a translation, please check the screenshot.

Regarding the templates, I found them to be at the post type 'footer' and 'header' respectively, please give it a try. You can filter by all post types and search for header and footer.

Alternatively you can try clicking on the following links directly and adding the translation from there by click on the + icon at the right bar:

Footer: hidden link
Header: hidden link

Thank you, please let us know.

home page.png
May 29, 2024 at 4:03 pm #15684931



I know it shows that + sign, but inside all the content is translated. PFA 100% translation completed

Same happens with Header & Footer it is 100% transated yet it is not visible.

May 29, 2024 at 8:57 pm #15685409

Mateus Getulio

Languages: English (English ) Portuguese (Brazil) (Português )

Timezone: America/Sao_Paulo (GMT-03:00)

Hello there,

I checked it and I noticed that your WordPress memory limit was set to 40MB while the PHP memory was defined as 2GB:

Debug info
PHP MemoryLimit	2048M
WP Memory Limit	40M

This was preventing the home page Portuguese translation from saving properly. The Spanish translation seems to be partially translated, it needs to reach 100% before you can save it, so it is a different issue.

I went ahead and updated the WP memory limit and tried to save the home page translation again and I can see it now(please check the screenshot):hidden link

Regarding the header, a similar issue was happening, by increasing the memory limit I was able to save the translation just fine and I can see it applied to the Portuguese pages.

I checked the footer but it is not 100% translated, can you please review it and finish translating it?

Once you translate the home page to Spanish(Portuguese is OK now) and the footer to Portuguese and Spanish, the rest should be covered by now.

Thank you,

This ticket is now closed. If you're a WPML client and need related help, please open a new support ticket.