WordPress Memory Limit Increase | WP Learning Lab


Nightmare!!! – David E in sales, Andy and Jason P are a detriment to this company. David E is sales completely lied and mislead me as the the services I would receive, and Andy and Jason ruined my entire website. I’m fairly certain the have little to no prior experience. It woukd take me many, many hours to write my entire experience, but here is a break down: – I was promised three things with my contraCT and I didn’t receive even on of the three. – My website turned out nothing like u was promised so I was forced to spend thousands of dollars on an outside vendor to clean up the mess. – management was rude and unresponsive -my Google AdWords accounts was damaged and I lost thousands on pointless advertising with broken site links thanks to #hostgator. -I was never offered any sort of apology or compensation for any of this. Not even a refund or an apology. Instead, I was ignored. That’s right, all of #hostgator began ignoring me including management. Nick, bangkok, Thailand


Grab Your Free 17-Point WordPress Pre-Launch PDF Checklist: http://vid.io/xqRL
Download our exclusive 10-Point WP Hardening Checklist: http://bit.ly/10point-wordpress-hardening-checklist
WordPress Memory Limit Increase | WP Learning Lab

define(‘WP_MEMORY_LIMIT’, ’64M’);

Exclusive for WPLearningLab viewers, up to 50% off hosting: https://wplearninglab.com/wordpress-hosting-offer/

In this tutorial you will learn how to increase the memory limit for your WordPress site. Usually the reason you want to do this is because a plugin or a theme is telling you that you need a higher memory limit for it to function properly.

Open your WordPress website’s wp-config file in cpanel or via FT. Paste the code below into it. You can paste it anywhere above where it says “Stop Editing. Happy Blogging”.

define(‘WP_MEMORY_LIMIT’, ’64M’);

The only thing you need to change in the snippet above is the ’64’. You can make that number whatever your plugin or theme is requesting. Usually it would be 64, 96, 128, or 256. I’ve never seen anything WordPress plugins or themes require more than 256.

Make sure you keep the “M” in the there. It tells WordPress that it’s megabytes.

If this change doesn’t fix the error then your host may be capping the WordPress PHP memory limit. Many hosts cap it at 8 megabytes, which isn’t much.

So that is how to increase WordPress PHP memory limit on your WordPress site.

Oh, one more thing. When you do a WordPress memory increase via the wp-config.php file the memory increase is only valid for that one website.

I hope this information helps you! If you have any questions leave a comment below or ping me @WPLearningLab on Twitter.

————–

If you want more excellent WordPress information check out our website where we post WordPress tutorials daily.

https://wplearninglab.com/

Connect with us:

WP Learning Lab Channel: http://www.youtube.com/subscription_center?add_user=wplearninglab

Facebook: https://www.facebook.com/wplearninglab

Twitter: https://twitter.com/WPLearningLab

Google Plus: http://google.com/+Wplearninglab

Pinterest: http://www.pinterest.com/wplearninglab/

WordPress Tutorials – WPLearningLab

42 Comments
  • Robert Martin
    Posted at 22:19h, 20 April

    96 worked for me. Thanks!

  • WordPress Tutorials - WPLearningLab
    Posted at 21:32h, 21 April

    I've created a playlist full of useful WordPress admin tweaks. If you want to level-up your admin dashboard check out the playlist here:

  • Brittany Quinn
    Posted at 23:22h, 24 April

    On cpanel I went to Select PHP version and changed my website to 1G on max file size and 512M memory which is the highest there is on Godaddy I don't believe there is a cap with Godaddy they guy from hosting support gave me instructions on increasing both memory and file size it's the highest. I hope my hosting people will help me figure out what's draining all the cpu or memory limit there however sometimes not very helpful and when you encounter these type of problems your on your own. I bet they want me to pay for additional resourses which sucks because I don't have the money. I had to start over from scratch my website has 5 post on it and 93 products from woo commerce I am running a cron job to keep products up to date. Its so frustrating before I was in the red all the time on both memory usage and cpu because of wp rocket a cache plugin. Now if I import products to woo commerce the memory usage and cpu will stay in the red all day. I only uploaded 30 products. I have a terrible feeling that if I don't pay for additional resourses that my hosting company will terminate my account. Ive already been getting warning emails.

  • lew shan
    Posted at 17:47h, 30 April

    it works ! thks !!

  • Hector Licón
    Posted at 18:00h, 06 May

    GREAT!!! Thank you for your help it fixed it.

  • Nazarii Banakh
    Posted at 17:55h, 30 May

    Thanks! Well done!

  • Kuba
    Posted at 11:07h, 11 June

    Thank you sir 🙂

  • MDRS English News
    Posted at 00:41h, 12 June

    hi sir i have add your code of 64mb but my wordpress is showing 32md, why?

  • Brittany Quinn
    Posted at 13:44h, 13 June

    wp learning lab now im having a message on cpanel that says file usage it's in the orage area any ideas how to fix this. I just dont get it my blog only has 10 post up.

  • Brittany Quinn
    Posted at 13:58h, 15 June

    wp learning lab i figured out why the file usage was orange. i figured out how to discover this in cpanel by looking at disk usage it just happened that i had a ton of junk in the trash.

    here is a report below of my disk usage

    please requesting advice or video about what these other files mean.

    wow i was suprised how much trash i had i was unaware the trash needed token out every once and awhile i believe it was holding more trash than anything.

    for some reason i thought if you used wp optimize and wp sweep these 2 plugins would clean everything.

    so happy its back in the green i thought my hosting company would have wanted me to upgrade to another hosting account.

    here is report thanks so much wp learning lab if you can give me some insight on this.

    Directory
    Contained Disk Usage

    MB
    Bytes

    /
    18000.92
    18875330560

     .appdata
    0.01
    12288

     .cagefs
    21.71
    22769664

     .cl.selector
    0.01
    8192

     .cpanel
    0.96
    1011712

     .cphorde
    0.45
    471040

     .htpasswds
    0.00
    0

     .mysql_backup
    0.86
    897024
    Owned by “root”.

     .subaccounts
    0.00
    4096

     .trash
    17573.02
    18426642432

     access-logs
    0.00
    0

     application_backups
    0.00
    0

     etc
    0.01
    8192

     logs
    1.98
    2080768

     mail
    0.67
    704512

     public_ftp
    0.00
    4096

     public_html
    395.91
    415145984

     tmp
    5.17
    5423104

     www
    0.00
    0

  • Damaris Muga
    Posted at 14:49h, 27 June

    THanks!!

  • Realtubetv
    Posted at 03:56h, 11 July

    thank you so much !!

  • Povilas Krūminis
    Posted at 10:30h, 14 July

    Thanks ! It works for me 🙂

  • Leth A
    Posted at 06:28h, 18 July

    Oh gosh! thanks a lot! I made mine to 96 and it works.. 64 didn't. This eoor happened after right installing JetPack. God bless you more.

  • Chronicl
    Posted at 22:02h, 21 July

    Worked thx (Y)

  • JOHN DAVEY
    Posted at 09:59h, 22 July

    top man 🙂 thank you for this, very easy to do, very well explained , sorted

  • Shantell Smith
    Posted at 07:00h, 24 July

    I used this code and it still didn't change anything. I am still getting this error. I get it when I try to upload pictures and when I try to do a back up with backwpup. do you have any other suggestions?

  • Rebecca Godfrey-Williams
    Posted at 13:54h, 26 July

    I got this message: "Parse error: syntax error, unexpected 'if' (T_IF) in sitename/wp-config.php on line 87" when i refreshed?

  • Frank Mann
    Posted at 06:39h, 13 August

    Great stuff

  • Aijaz Shaan
    Posted at 19:11h, 18 August

    BEST EASY WAY TO DO IS:
    Tuxedo Big File Uploads plugins

  • Aslan Abeussdyk
    Posted at 14:42h, 21 August

    God thanks! like!

  • Quan Phan
    Posted at 11:46h, 17 September

    thank for your great video! i have another problem when installing a new application in wordpress with godaddy hosting. the error show "Unable to create a database. Check that your hosting account has at least one database available. If it does, please contact your host"… please give me some ideas/advise… thank you

    Technical Error: You have exceeded the maximum allowed databases

  • SwiftPropel
    Posted at 19:40h, 21 October

    thanks!

  • Allendale Fibertech
    Posted at 17:53h, 04 November

    awesome, worked for me!! thank you!

  • Ranma
    Posted at 22:34h, 26 November

    doesn´t work for me, i have godaddy cpanel, no change nothing -_-

  • My Gmail
    Posted at 12:59h, 27 February

    Thank you SOOOO much – you really helped me solve the issue.

  • Zero 2 Wealth
    Posted at 18:33h, 23 May

    SUUUPER EASY! It worked like a charm! I'm not worthy! Thanks!!!!

  • Rafa Technology
    Posted at 06:58h, 10 June

    My situation is owful, it never open, and i already re-installet wordpress several times but i get the same thing. please i really need help quick. also i followed every step in this video.. please help me! My WhatsApp: +1829 436 4744

  • Delwer Hossain
    Posted at 07:09h, 26 July

    nice solution.

  • Online Quran
    Posted at 19:43h, 01 August

    nothing happened for me. used chrome. checked many times nothing happened.

  • Kushal Arora
    Posted at 07:59h, 03 August

    It worked man thanks

  • carstuff
    Posted at 21:16h, 10 September

    Only works when I use your code. Thanks brother

  • Mike Burns / Arranged Accidents
    Posted at 20:54h, 29 September

    Bingo Bongo Booyah! My host help desk couldn't figure it out but this worked!

  • Gary Hamm
    Posted at 18:28h, 29 October

    Bjorn, Everything is working perfect. I boosted it up to 96 and it shows 96M…

  • Lars Stryhn
    Posted at 23:34h, 10 November

    Thanks!

  • ASIRIZE HEALTH
    Posted at 15:44h, 12 November

    THX BIG TIME

  • Pancho Labrador
    Posted at 03:57h, 03 December

    thanks! it worked

  • Raf Dah
    Posted at 01:49h, 31 December

    thanks that fixed my problem 🙂

  • Jayne Bachelor
    Posted at 03:10h, 17 January

    Thank you that was exactly what my problem was and your video was super easy to follow.

  • Mindsetxstyle
    Posted at 19:51h, 19 February

    so… i can't neither over extend the memory_limit right?… because i put mine in 1024…

  • Aleem Uddin
    Posted at 18:32h, 24 February

    Whenever I tries to add wp_enqueue_scripts('main-university-js', get_theme_file_uri('/js/scripts-bundled.js'), NULL, '2.O', true); in my function.php file. It gives me a fatal memory error. I am using local host xamp

  • Zach McMinimy
    Posted at 23:40h, 29 March

    KING