Home » Php » What is the maximum size of an array in PHP?

What is the maximum size of an array in PHP?

Posted by: admin November 29, 2017 Leave a comment

Questions:

We like to store database values in array. But we do not know the maximum size of an array which is allowed in PHP?

Answers:

There is no max on the limit of an array. There is a limit on the amount of memory your script can use. This can be changed in the ‘memory_limit’ in your php.ini configuration.

Questions:
Answers:

Array size is limited only by amount of memory your server has. If your array gets too big, you will get “out of memory” error.