Magento ver.

Getting fatal error while setup magento project on localhost. Localhost config: PHP 5.6.33-3+ubuntu16.04.1+deb.sury.org+1 (cli) mysql Ver 14.14 Distrib 5.7.11 apache

enter image description here

1 Answer 1


Try this,

Increasing max_nesting_level value

Edit the php.ini file and search for [xdebug]. You should find a block containing the xdebug extension location and settings.

See if there is already an entry xdebug.max_nesting_level, if not, just add it at the end of the block with a higher value than 100:


Try increasing it if 256 is not sufficient.

Taken from: http://docs.gantry.org/gantry5/troubleshooting/max-nesting-level

  • No Luck. Please, suggest more. Commented Mar 6, 2018 at 11:18
  • I believe this is the correct answer, but for Magento you need to increase it a lot. Try 1500 or higher.
    – tecjam
    Commented Sep 9, 2019 at 18:18

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.