Troubleshooting · Troubleshooting
How to Fix Menus That Won't Save in WordPress
Short answer
A WordPress menu usually fails to save because the PHP max_input_vars limit cuts off part of the form, a plugin or theme blocks the save, or the menu was edited in the wrong place for the theme. Check the limit in Tools > Site Health > Info, raise it with your host if it is low, then save again and confirm every item is still there.
Key takeaways
- PHP max_input_vars defaults to 1000, and extra menu fields past that limit are cut off when you save.
- A large menu can lose its last items, its order, or its theme location after a save.
- Tools > Site Health > Info shows the live max_input_vars value under Server.
- Health Check Troubleshooting Mode tests a menu save with plugins off, for your session only.
- In a block theme, edit navigation in the Site Editor, not only in Appearance > Menus.
- If the save still fails after these checks, ask your host to raise the limit or check the server firewall.
Why won't my WordPress menu save?
A menu usually fails to save because the server cuts off the form, a plugin or theme blocks the request, or you edited it in the wrong place.
The most common cause is a large menu. Each menu item sends several fields when you click Save Menu, so a menu with many items can pass the server limit even when the page looks normal.
Start with the simplest test first. Make one small change, such as renaming one item, click Save Menu, reload the page, and see if that change stayed.
If a small change saves but a large change does not, the problem is likely the input limit in the next section. If no change saves at all, move to the plugin, role, and firewall checks below.
What does max_input_vars do to a menu?
The PHP setting max_input_vars sets how many form fields PHP accepts in one request, and fields past that limit are dropped.
PHP.net lists the default value as 1000, and it says the limit applies to $_GET, $_POST, and $_COOKIE separately. When a request has more input variables than the limit, PHP issues an E_WARNING and truncates the extra input from the request.
A menu save is one big form. Every item can send a label, a URL, a parent ID, an order value, and extra fields, so 100 items can send far more than 1000 fields.
The WordPress.org page for the If Menu plugin describes the same fault in plain terms: changes are not saved on sites with many menu items because the host limits the data sent for saving, and the setting to raise is max_input_vars, for example from 200 to 500. See If Menu.
| Menu size | Likely fields sent | What to try first |
|---|---|---|
| Under 30 items | Under 1000 | Check plugins, roles, and theme location first |
| 30 to 80 items | Around 1000 to 3000 | Raise max_input_vars to 3000 |
| 80 to 150 items | Around 3000 to 6000 | Raise max_input_vars to 5000 or higher |
| Over 150 items | Over 6000 | Raise the limit and split the menu if you can |
How do I check my current max_input_vars value?
Open Tools > Site Health > Info > Server in WordPress and read the PHP max input variables value shown there.
That screen lists the live server value, so it shows what your site is actually using.
The Kinsta guide to WordPress 5.2 notes that Site Health Info lists PHP max input variables, time limit, memory limit, max input time, and upload limits under the Server section. See Kinsta.
Follow these steps:
- Go to Tools > Site Health in WordPress.
- Click the Info tab at the top.
- Open the Server section.
- Find PHP max input variables and note the number.
- Compare that number with the size of your menu.
If the value is 1000 and your menu is large, you have a likely cause. If the value is already 5000 or higher and the menu still fails, the cause is more likely a plugin, a theme, or a firewall rule.
How do I raise max_input_vars safely?
Ask your host to raise max_input_vars, or change it in your PHP settings if your host gives you that control.
Do not set it to a huge number at once. Raise it in steps, save the menu after each step, and stop at the lowest value that saves the full menu.
Use these steps:
- Back up the site first, so you can restore it if a config change breaks access. See the guide to backing up WordPress before you edit server files.
- Open your host control panel and find the PHP settings or PHP version area.
- Set
max_input_varsto 3000, then save the setting. - Reload Tools > Site Health > Info > Server and confirm the new value shows.
- Save the menu again and check that every item stayed.
- If items still drop off, raise the value to 5000 and repeat the check.
Kinsta lists max_input_vars as 10000 for its lower plans and 15000 for its higher plans, as of November 2026, and says to contact Support about changes. See Kinsta Technical FAQ. That shows how far hosts can set the value, but it does not mean every site needs 10000.
If your host will not raise the limit, split the menu. Use a smaller main menu and a second menu for the footer or for a section page, so each save sends fewer fields.
Why does only part of my menu disappear after saving?
Only part of a menu disappears because PHP drops the fields past the limit, so the last items in the form are the ones lost.
The save does not fail with a clear error in this case. WordPress saves the items it received, and the items past the limit simply never reach the database.
Watch for these signs:
- The last items you added are gone after a reload.
- Submenu items lose their parent and move to the top level.
- A menu location is unchecked after you save.
- The menu looks fine in the editor, then changes after you reload the page.
Count the items before you save, then count them again after a reload. If the same items vanish each time, and the count stops near the same place, the input limit is the likely cause.
Could a plugin or theme stop a menu from saving?
Yes, a plugin or theme can stop a menu save by adding extra fields, changing menu data, or blocking the request.
Menu plugins, mega menu plugins, and plugins that add icons, images, or visibility rules to each item add fields to the save. Those extra fields use up the input limit faster, so a menu that saved before can fail after you add such a plugin.
Test with Health Check Troubleshooting Mode:
- Install and activate Health Check & Troubleshooting from Plugins > Add New.
- Go to Tools > Site Health > Troubleshooting.
- Click Enable Troubleshooting Mode.
- Try the same menu save with all plugins off and a default theme active.
- If the save works, turn plugins back on one at a time and save after each one.
Troubleshooting Mode only changes your session, so visitors still see the normal site while you test. The plugin page on WordPress.org describes it as a free plugin from the WordPress.org community. See Health Check & Troubleshooting.
Am I editing the menu in the wrong place for my theme?
You may be editing the wrong place if you use a block theme, because block themes manage navigation in the Site Editor, not only in Appearance > Menus.
WordPress.org docs say WordPress 5.9 was the last version to include the Appearance Menus screen for all sites by default. In WordPress 6.0 and later, when you use a block theme, navigation is managed via the Navigation block. See Appearance Menus Screen.
Check your theme type first:
- Classic theme: use Appearance > Menus, then assign the menu under Menu Settings > Display location.
- Block theme: go to Appearance > Editor, select the Navigation block, and edit the menu there.
- Hybrid theme: try the Site Editor first, then check if Appearance > Menus is still present.
Learn WordPress notes that menus created in classic themes are available in block themes, so an old menu may still exist even if the edit screen moved. See How to Create a Menu with the Navigation Block.
A common fault is saving a menu but not assigning it. In Appearance > Menus, scroll to Menu Settings, tick the location you want, then click Save Menu again. The docs say you can add a new menu to a Theme Location only if your theme supports custom menus.
Why does Save Menu spin, time out, or show a blank page?
A save can spin or time out when the request is too large, the server is slow, or a security rule blocks the request.
PHP.net lists the default max_execution_time as 30 seconds, so a slow save on a large menu can hit that limit before it finishes. Check the pattern:
- Save spins for 30 seconds, then fails: check the time limit and the host.
- Save fails at once with a 403 error: check the firewall or security plugin.
- Save shows a blank page: turn on logging and check
debug.logbefore you save again.
For a 403 error, look at Cloudflare or your security plugin first.
Cloudflare docs say its WAF Managed Rulesets are pre-configured rulesets that protect against a range of attacks and are updated often. Its Free Managed Ruleset includes rules for very common WordPress exploits. See Cloudflare.
A rule can block a menu save that looks like an attack, so check the firewall events for your save time.
If the page goes blank, enable logging in wp-config.php with WP_DEBUG set to true, WP_DEBUG_LOG set to true, and WP_DEBUG_DISPLAY set to false.
WordPress docs say WP_DEBUG is false by default in a standard install, and WP_DEBUG_LOG writes errors to wp-content/debug.log. See Debugging in WordPress. Turn debug mode off after you find the cause.
A timeout fault can also come from a slow host, so note the exact time the save fails and share it with support.
How do I know the fix worked?
The fix worked when a small change, a large change, and a reload all keep the same menu items, order, and location.
Do this check in order:
- Count the menu items before you save and write the number down.
- Add one new item, move one item, and change one label.
- Click Save Menu and wait for the page to reload.
- Reload Appearance > Menus again and count the items.
- Check the order, the submenu parents, and the ticked Display location.
- Open the live site in a new tab and check the menu there.
If the menu still looks old on the live site after a good save, clear the cache. A stale cache can hide a saved menu, and that is a different fault from a failed save. See the guide to changes not showing on the live site.
When should I contact my host?
Contact your host when the limit will not change, the save times out, or the server blocks the request.
Ask for these 3 things in one message:
- The current
max_input_varsvalue, and a raise to 3000 or 5000. - The current
max_execution_timevalue, and whether a menu save hit it. - Any firewall or ModSecurity rule that blocked a POST to
/wp-admin/nav-menus.phpat the time you saved.
Give the host the exact time, the menu name, and the number of items. That lets support check the right log entries instead of guessing.
If you cannot log in at all, or the admin area shows a 500 error after a save, contact the host at once. See the guide to being locked out of wp-admin for the steps to try first, then ask the host to check the error log.
What mistakes should you avoid?
Avoid editing the live menu without a backup, raising limits to extreme values, and saving a huge menu in one go.
- Do not edit
php.inior.htaccesswithout a backup, because a bad line can lock you out of the site. - Do not set
max_input_varsto 100000 to “fix it for good”, because a very high limit can let a bad request use more server resources. - Do not add 100 items at once, then save. Add items in groups of 20, save, and check the count.
- Do not skip the location check. A saved menu with no ticked location will not show on the site.
- Do not leave
WP_DEBUG_DISPLAYon after testing, because errors can show on live pages. - Do not keep a plugin that breaks every menu save. Update it, replace it, or ask its author for a fix.
If you change a theme or switch to a block theme, check where menus are edited before you rebuild the menu. A menu built in the wrong editor can look saved, then vanish from the header.
Frequently asked questions
How many menu items can WordPress save at once?
There is no fixed WordPress limit on menu items. The real limit comes from PHP max_input_vars, which defaults to 1000 fields per request. Each menu item sends several fields, so a menu with 80 to 100 items can pass that limit. Raise the limit, or split a very large menu into two smaller menus.
Why does my menu save in the editor but not show on the site?
The menu may be saved but not assigned to a location. In Appearance > Menus, scroll to Menu Settings, tick the Display location you want, and click Save Menu again. In a block theme, check the Navigation block in the Site Editor instead, because that is where the header menu is set.
Can a plugin cause a menu not to save?
Yes. A plugin that adds fields, icons, or visibility rules to each menu item sends more data with every save, so it can push a large menu past the input limit. Test the save in Health Check Troubleshooting Mode, then turn plugins back on one at a time to find the one that breaks it.
What max_input_vars value should I use for a large menu?
Start at 3000 for a menu with 30 to 80 items, then try 5000 if items still drop off. Confirm the new value in Tools > Site Health > Info > Server before you save again. Do not set an extreme value, and split a menu with more than 150 items if your host will not raise the limit.
Should I edit php.ini or .htaccess to raise max_input_vars?
Use your host control panel first, and ask your host if that option is not shown. Some hosts block changes in .htaccess, and a bad line in either file can break the site. Back up the site before you edit a server file, and check Site Health after the change to confirm the new value took effect.
Sources
- Appearance Menus Screen WordPress.org
- PHP Runtime Configuration PHP.net
- If Menu – Visibility control for Menus WordPress.org
- Roles and Capabilities WordPress.org
- Debugging in WordPress WordPress.org
- Health Check & Troubleshooting WordPress.org
- How to Create a Menu with the Navigation Block Learn WordPress
- Technical FAQ Kinsta
Is your product missing, or something out of date?
Tell us what to add or correct. We read every note and reply when we need a source. A message does not buy a ranking.
Thanks — we review requests within 3 business days.
