{"id":9131,"date":"2026-05-31T20:13:25","date_gmt":"2026-05-31T18:13:25","guid":{"rendered":"https:\/\/mybox.com\/help\/?post_type=manual_kb&#038;p=9131"},"modified":"2026-05-31T20:13:26","modified_gmt":"2026-05-31T18:13:26","slug":"how-to-change-php-parameters-and-limits","status":"publish","type":"manual_kb","link":"https:\/\/mybox.com\/help\/en\/knowledgebase\/how-to-change-php-parameters-and-limits\/","title":{"rendered":"How to change PHP parameters and limits"},"content":{"rendered":"\n<div class=\"translation-block translation-block-merged\">\n<p class=\"wp-block-paragraph\">PHP parameters define how your website behaves at the server level. They control limits such as memory usage, file upload size, and script execution time.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">In mybox hosting, these settings can be adjusted using the <code>.htaccess<\/code> file in your website\u2019s main directory.<\/p>\n\n\n\n<div id=\"ez-toc-container\" class=\"ez-toc-v2_0_86 ez-toc-wrap-left counter-hierarchy ez-toc-counter ez-toc-custom ez-toc-container-direction\">\n<div class=\"ez-toc-title-container\">\n<p class=\"ez-toc-title\" style=\"cursor:inherit\">Table of Contents<\/p>\n<span class=\"ez-toc-title-toggle\"><\/span><\/div>\n<nav><ul class='ez-toc-list ez-toc-list-level-1 ' ><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-1\" href=\"https:\/\/mybox.com\/help\/en\/knowledgebase\/how-to-change-php-parameters-and-limits\/#How_to_check_current_PHP_settings\" >How to check current PHP settings<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-2\" href=\"https:\/\/mybox.com\/help\/en\/knowledgebase\/how-to-change-php-parameters-and-limits\/#How_PHP_parameter_changes_work\" >How PHP parameter changes work<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-3\" href=\"https:\/\/mybox.com\/help\/en\/knowledgebase\/how-to-change-php-parameters-and-limits\/#Default_PHP_values_example\" >Default PHP values (example)<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-4\" href=\"https:\/\/mybox.com\/help\/en\/knowledgebase\/how-to-change-php-parameters-and-limits\/#Examples_of_PHP_configuration_changes\" >Examples of PHP configuration changes<\/a><ul class='ez-toc-list-level-3' ><li class='ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-5\" href=\"https:\/\/mybox.com\/help\/en\/knowledgebase\/how-to-change-php-parameters-and-limits\/#Increase_memory_limit\" >Increase memory limit<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-6\" href=\"https:\/\/mybox.com\/help\/en\/knowledgebase\/how-to-change-php-parameters-and-limits\/#Increase_maximum_upload_size\" >Increase maximum upload size<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-7\" href=\"https:\/\/mybox.com\/help\/en\/knowledgebase\/how-to-change-php-parameters-and-limits\/#Increase_maximum_POST_size\" >Increase maximum POST size<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-8\" href=\"https:\/\/mybox.com\/help\/en\/knowledgebase\/how-to-change-php-parameters-and-limits\/#Increase_script_execution_time\" >Increase script execution time<\/a><\/li><\/ul><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-9\" href=\"https:\/\/mybox.com\/help\/en\/knowledgebase\/how-to-change-php-parameters-and-limits\/#Where_to_apply_these_changes\" >Where to apply these changes<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-10\" href=\"https:\/\/mybox.com\/help\/en\/knowledgebase\/how-to-change-php-parameters-and-limits\/#Important_limitations\" >Important limitations<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-11\" href=\"https:\/\/mybox.com\/help\/en\/knowledgebase\/how-to-change-php-parameters-and-limits\/#Practical_implications\" >Practical implications<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-12\" href=\"https:\/\/mybox.com\/help\/en\/knowledgebase\/how-to-change-php-parameters-and-limits\/#Summary\" >Summary<\/a><\/li><\/ul><\/nav><\/div>\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"How_to_check_current_PHP_settings\"><\/span>How to check current PHP settings<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<\/div>\n\n<div id=\"mybox-598332852\" class=\"mybox-content mybox-entity-placement\"><div class=\"early-access-banner-inpost\">\r\n  <div class=\"banner-left-inpost\">\r\n    <div class=\"icon-box-inpost\">\r\n      <img decoding=\"async\" src=\"https:\/\/mybox.com\/help\/wp-content\/uploads\/2026\/02\/square-info-icon.svg\" alt=\"Info\">\r\n    <\/div>\r\n    <div class=\"text-box-inpost\">\r\n      <span class=\"label-inpost\"><span class=\"translation-block translation-block-banner-text\">Early access<\/span><\/span>\r\n      <h4><span class=\"translation-block translation-block-banner-text\">Still need help?<\/span><\/h4>\r\n      <p><span class=\"translation-block translation-block-banner-text\">Contact our customer service team.<\/span><\/p>\r\n    <\/div>\r\n  <\/div>\r\n\r\n  <div class=\"banner-right-inpost\">\r\n    <a href=\"https:\/\/panel.mybox.com\/helpdesk2\/v\/list\/\" class=\"banner-button-inpost\"><span class=\"translation-block translation-block-banner-text\">Message us<\/span><\/a>\r\n  <\/div>\r\n<\/div><\/div>\n\n<div class=\"translation-block translation-block-merged\"><p class=\"wp-block-paragraph\">You can view your current PHP configuration using the <code>phpinfo()<\/code> function. Learn how to do it <a href=\"https:\/\/mybox.com\/help\/en\/knowledgebase\/information-about-current-php-parameters-phpinfo\/\" data-type=\"link\" data-id=\"https:\/\/mybox.com\/help\/en\/knowledgebase\/information-about-current-php-parameters-phpinfo\/\">HERE<\/a>.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"How_PHP_parameter_changes_work\"><\/span>How PHP parameter changes work<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">PHP settings can be overridden by adding directives to the <code>.htaccess<\/code> file located in the main directory of your website (usually <code>public_html<\/code>).<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Each setting uses the following structure:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>php_value parameter_name value\n<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">For example:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>php_value memory_limit 8192M\n<\/code><\/pre>\n\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"Default_PHP_values_example\"><\/span>Default PHP values (example)<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Typical default values in a hosting environment may include:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>memory_limit 8192M\npost_max_size 8192M\nupload_max_filesize 2048M\nmax_execution_time 3000\n<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">These values determine how much server resource your PHP scripts can use.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"Examples_of_PHP_configuration_changes\"><\/span>Examples of PHP configuration changes<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<h3 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"Increase_memory_limit\"><\/span>Increase memory limit<span class=\"ez-toc-section-end\"><\/span><\/h3>\n\n\n\n<pre class=\"wp-block-code\"><code>php_value memory_limit 1024M\n<\/code><\/pre>\n\n\n\n<h3 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"Increase_maximum_upload_size\"><\/span>Increase maximum upload size<span class=\"ez-toc-section-end\"><\/span><\/h3>\n\n\n\n<pre class=\"wp-block-code\"><code>php_value upload_max_filesize 512M\n<\/code><\/pre>\n\n\n\n<h3 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"Increase_maximum_POST_size\"><\/span>Increase maximum POST size<span class=\"ez-toc-section-end\"><\/span><\/h3>\n\n\n\n<pre class=\"wp-block-code\"><code>php_value post_max_size 512M\n<\/code><\/pre>\n\n\n\n<h3 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"Increase_script_execution_time\"><\/span>Increase script execution time<span class=\"ez-toc-section-end\"><\/span><\/h3>\n\n\n\n<pre class=\"wp-block-code\"><code>php_value max_execution_time 300\n<\/code><\/pre>\n\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"Where_to_apply_these_changes\"><\/span>Where to apply these changes<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Edit the <code>.htaccess<\/code> file located in your website root directory:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>public_html\/.htaccess\n<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">If the file does not exist, you can create it manually.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"Important_limitations\"><\/span>Important limitations<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Not all PHP directives can be changed using <code>.htaccess<\/code>.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Only settings belonging to:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li><code>PHP_INI_ALL<\/code><\/li>\n\n\n\n<li><code>PHP_INI_PERDIR<\/code><\/li>\n<\/ul>\n\n\n\n<p class=\"wp-block-paragraph\">can be modified this way.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Some system-level settings are restricted and cannot be overridden at the hosting level.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"Practical_implications\"><\/span>Practical implications<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Incorrect configuration in <code>.htaccess<\/code> may cause your website to stop working.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">If this happens, you can restore functionality by removing or correcting the added PHP directives.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Changes take effect immediately after the <code>.htaccess<\/code> file is saved.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"Summary\"><\/span>Summary<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">PHP parameters in mybox can be adjusted using <code>.htaccess<\/code> directives in the website root directory. These settings allow you to control memory limits, upload sizes, and execution time, within the limits allowed by the server configuration.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><\/p>\n<\/div>\n","protected":false},"author":1,"featured_media":0,"parent":0,"menu_order":0,"template":"","format":"standard","manualknowledgebasecat":[39],"manual_kb_tag":[718,2319,2320,2321,3896,5110,5380,5384,5941,5942],"class_list":["post-9131","manual_kb","type-manual_kb","status-publish","format-standard","hentry","manualknowledgebasecat-php-operations","manual_kb_tag-htaccess-file","manual_kb_tag-php-configuration","manual_kb_tag-php-settings","manual_kb_tag-php-parameters","manual_kb_tag-max-execution-time","manual_kb_tag-memory-limit","manual_kb_tag-upload-max-filesize","manual_kb_tag-post-max-size","manual_kb_tag-htaccess-directives","manual_kb_tag-php-value-directives"],"_links":{"self":[{"href":"https:\/\/mybox.com\/help\/en\/wp-json\/wp\/v2\/manual_kb\/9131","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/mybox.com\/help\/en\/wp-json\/wp\/v2\/manual_kb"}],"about":[{"href":"https:\/\/mybox.com\/help\/en\/wp-json\/wp\/v2\/types\/manual_kb"}],"author":[{"embeddable":true,"href":"https:\/\/mybox.com\/help\/en\/wp-json\/wp\/v2\/users\/1"}],"version-history":[{"count":1,"href":"https:\/\/mybox.com\/help\/en\/wp-json\/wp\/v2\/manual_kb\/9131\/revisions"}],"predecessor-version":[{"id":9132,"href":"https:\/\/mybox.com\/help\/en\/wp-json\/wp\/v2\/manual_kb\/9131\/revisions\/9132"}],"wp:attachment":[{"href":"https:\/\/mybox.com\/help\/en\/wp-json\/wp\/v2\/media?parent=9131"}],"wp:term":[{"taxonomy":"manualknowledgebasecat","embeddable":true,"href":"https:\/\/mybox.com\/help\/en\/wp-json\/wp\/v2\/manualknowledgebasecat?post=9131"},{"taxonomy":"manual_kb_tag","embeddable":true,"href":"https:\/\/mybox.com\/help\/en\/wp-json\/wp\/v2\/manual_kb_tag?post=9131"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}