WebGeniusLab logo
  • All Themes
  • Premium Themes
  • Hire Us
  • Support
  • Contacts
Browse Themes
WebGeniusLab logo
WebGeniusLab logo white
  • All Themes
  • Premium Themes
  • Hire Us
  • Support
  • Contacts
Home/Blog/Basics/How to Increase PHP Memory Limit, max_input_vars, and Upload Size in WordPress

How to Increase PHP Memory Limit, max_input_vars, and Upload Size in WordPress

June 26, 2026by Sam Rodman
php_max_vars
BasicsWordPress

After installing a WordPress theme you may see warnings in the Theme Dashboard: insufficient PHP memory, file upload limit too low, or max_input_vars too small. All three are PHP configuration values that can be adjusted without touching WordPress core. Here’s how to fix each one.

1. Increase PHP Memory Limit

WordPress requests 40 MB of PHP memory by default, but modern themes and plugins — Elementor, WPBakery, Revolution Slider — need at least 256 MB to run reliably.

Method 1: wp-config.php (recommended)

Open wp-config.php in the site root and add the following line before “That’s all, stop editing!”:

define( 'WP_MEMORY_LIMIT', '256M' );

Method 2: .htaccess (Apache servers)

php_value memory_limit 256M

Method 3: php.ini

memory_limit = 256M

Note: If your hosting plan does not allow changing this value, contact your host’s support or upgrade to a plan with a higher memory limit.

2. Increase Maximum File Upload Size

By default PHP limits uploaded files to 2–8 MB depending on the server. You’ll need a higher value when importing demo content, uploading videos, or working with large images.

Method 1: .htaccess

php_value upload_max_filesize 64M
php_value post_max_size 64M

Method 2: php.ini

upload_max_filesize = 64M
post_max_size = 64M

Method 3: wp-config.php

@ini_set( 'upload_max_size', '64M' );
@ini_set( 'post_max_size', '64M' );

Note: post_max_size must be equal to or larger than upload_max_filesize. If post_max_size is smaller, the effective upload limit will not increase.

3. Increase max_input_vars

max_input_vars caps the number of fields that can be submitted in a single POST request. Themes with large options panels (Redux Framework, Kirki) may silently fail to save settings when this value is too low. 3000 or higher is recommended.

Method 1: .htaccess

php_value max_input_vars 3000

Method 2: php.ini

max_input_vars = 3000

Note: After editing php.ini, restart PHP-FPM (php-fpm reload) or Apache for the changes to take effect.

How to Check Current Values

Go to WordPress Admin → Appearance → Theme Dashboard → System Status. This page displays all current PHP values and flags anything that falls below the recommended threshold.

Recommended Minimum Values

  • memory_limit — 256M
  • upload_max_filesize — 32M (64M for demo import)
  • post_max_size — 64M
  • max_input_vars — 3000
  • max_execution_time — 300
prev
How to Activate Your WebGeniusLab Theme: Purchase Code vs. License Key

How to Activate Your WebGeniusLab Theme: Purchase Code vs. License Key

next

How to Speed Up an Elementor Website: 6 Proven Optimizations

How to Speed Up an Elementor Website: 6 Proven Optimizations

Related Posts

elementor_speed_up
BasicsElementor
June 26, 2026

How to Speed Up an Elementor Website: 6 Proven Optimizations

Read More
wgl_wordpress_activation
BasicsWordPress
June 26, 2026

How to Activate Your WebGeniusLab Theme: Purchase Code vs. License Key

Read More
Categories
  • Basics
  • Elementor
  • WordPress
Recent Posts
  • How to Speed Up an Elementor Website: 6 Proven Optimizations
  • How to Increase PHP Memory Limit, max_input_vars, and Upload Size in WordPress
  • How to Activate Your WebGeniusLab Theme: Purchase Code vs. License Key
WebGeniusLab logo white

We create premium WordPress themes for modern businesses — clean design, powerful functionality, and exceptional user experience.

 

FacebookInstagramTelegram-plane

Themes

All Themes

Popular Themes

Best Sellers

Contacts

Support hours

8:00 – 17:00 CET, Mon–Fri

!

All support is handled through our community forum only — no direct email support.

General inquiries

webgeniuslab@gmail.com

Helpful Links

Support Centre

Customization

Terms & Conditions

Reporting Vulnerabilities

Blog

Subscribe

Want the best deals, new theme releases and exclusive discounts? Subscribe and be the first to know.

    © 2026 WebGeniusLab. All Rights Reserved.

    Privacy Policy

    Refund Policy

    Manage Consent

    We use cookies to enhance your experience by collecting data like browsing behavior. You can opt out of data sharing via our link. Opting out may affect some site features.

    Functional Always active
    The technical storage or access is strictly necessary for the legitimate purpose of enabling the use of a specific service explicitly requested by the subscriber or user, or for the sole purpose of carrying out the transmission of a communication over an electronic communications network.
    Preferences
    The technical storage or access is necessary for the legitimate purpose of storing preferences that are not requested by the subscriber or user.
    Statistics
    The technical storage or access that is used exclusively for statistical purposes. The technical storage or access that is used exclusively for anonymous statistical purposes. Without a subpoena, voluntary compliance on the part of your Internet Service Provider, or additional records from a third party, information stored or retrieved for this purpose alone cannot usually be used to identify you.
    Marketing
    The technical storage or access is required to create user profiles to send advertising, or to track the user on a website or across several websites for similar marketing purposes.
    • Manage options
    • Manage services
    • Manage {vendor_count} vendors
    • Read more about these purposes
    View preferences
    • {title}
    • {title}
    • {title}