Home Forums Backend Issues (wp-admin) max_input_vars solution not working for me


max_input_vars solution not working for me

  • Hi,
    for a client I have to fix a problem. At the moment he can’t save more than 66 fields in an ACF-Group. I was researching a bit and found out, that one possible problem could be, that the max_input_vars in the php.ini is too low, so PHP rejects the POST-Values after 1.000 fields. I was checking and indeed the Form was sending more than 1.000 fields.

    I first tried the .htaccess-Solution as described e.g. here:
    and in this blog post:

    But, this produced an Error 500 because the machine is (as I found out) running as FastCGI. For people with this problem, check the possibilty of the user.ini:

    So I translated the .htaccess to the .user.ini and uploaded this file.

    max_input_vars = 5000
    max_input_time = 300
    max_input_nesting_level = 128
    max_execution_time = 300
    post_max_size = 32M

    <?php phpinfo(); ?> displays set the new values are set as local values for PHP now.

    But unfortunatly still, after uploading and everything, I am not able to save more than these 66 fields. Now, I have no further idea, what to do. Does anyone has an suggesstion?

    Thanks a lot!

  • Hi @websupporter

    Thanks for all the information, but unfortunately, I’m just a PHP programmer specializing in UI, so I don’t realy have much knowledge of server configuration / limitations.

    Perhaps you could post a link to this on a general PHP forum such as stack overflow? I’m sure there are some guns out there that will be able to solve the issue for you.

    Sorry I can’t be of much other help.


  • Hi @elliot,
    thanks for your help. I asked now in Stockoverflow.

    If I find a solution, I will share it here.

    All the best

  • I have the same issue today and found this post.

    the max number of fields allowed is 66

    as we both have the same restriction – may not be a server issue?

    I tried all the things above that you did and got the same result.

    I am using this to help a client easily add images and text to an html slider code so need at least 150 fields just to start with.

    Any ideas?

  • Hi Websupporter

    just wanted to let you know that I rolled back to 4.1.8 (svn) and can now add more fields

    the issue seems to have occurred in 4.2.0 (svn)

  • spoke to soon – the max for this one seems to be 70

  • Ok searching for this problem was killing me!

    Don’t forget to consider this:

    “I had the same problem and it turned out that because the server was using the Suhosin patch I also needed to set the following my .htaccess file: = 20000
    suhosin.request.max_vars = 20000”

    I found it on stackoverflow and it solved my problem. Nobody speaks about this on ACF support forums.

    See u 🙂

  • @cleocq

    Many many many thanks!! This problem was bugging me over hours …

Viewing 8 posts - 1 through 8 (of 8 total)

The topic ‘max_input_vars solution not working for me’ is closed to new replies.