If you are using WordPress and changes made in Divi, Elementor, or another page builder will not save, the problem may be caused by a missing or incorrect .htaccess file.
This can sometimes happen after moving a WordPress website, restoring a backup, changing the document root, or manually uploading WordPress files.
Common Symptoms
You may notice that:
- Divi or another WordPress page builder will not save changes.
- Images can be changed in the editor, but the changes will not save.
- The WordPress editor gives an error when saving or publishing.
- Some WordPress REST API requests fail.
- Certain WordPress pages or links do not work correctly.
If you are seeing these problems, check that WordPress has a working .htaccess file.
Why Does WordPress Need the .htaccess File?
On DataPacket Linux Web Hosting servers using Apache, WordPress uses the .htaccess file for URL rewriting and other request handling.
WordPress page builders such as Divi often use the WordPress REST API in the background when you edit and save a page. If the .htaccess file is missing or does not contain the normal WordPress rewrite rules, these requests may not work correctly.
This can cause Divi or another WordPress editor to fail when trying to save changes.
How to Fix a Missing WordPress .htaccess File
The easiest way to have WordPress rebuild its rewrite rules is through the WordPress dashboard.
Log in to your WordPress administrator area and go to:
- Settings → Permalinks
You do not normally need to change anything. Simply click Save Changes.
WordPress will attempt to create or update the .htaccess file with the rewrite rules it needs.
After saving the permalink settings, return to Divi or your WordPress editor and try saving the page again.
Manually Restore the WordPress .htaccess File
If WordPress cannot create the file automatically, you can create a file named:
.htaccess
Place it in the main directory of your WordPress installation. This is normally the same directory containing wp-admin, wp-content, and wp-includes.
For a standard WordPress installation, the default rules are:
# BEGIN WordPress<IfModule mod_rewrite.c>RewriteEngine OnRewriteRule .* - [E=HTTP_AUTHORIZATION:%{HTTP:Authorization}]RewriteBase /RewriteRule ^index\.php$ - [L]RewriteCond %{REQUEST_FILENAME} !-fRewriteCond %{REQUEST_FILENAME} !-dRewriteRule . /index.php [L]</IfModule># END WordPress
If WordPress is installed in a subdirectory, your rewrite rules may be different. In that case, using Settings → Permalinks → Save Changes is usually the better option because WordPress can generate the correct rules for the installation.
Check the File in Plesk
DataPacket Web Hosting customers can also check for the file using Plesk File Manager.
Open your domain in Plesk, select File Manager, and browse to the directory where WordPress is installed.
Look for:
.htaccess
Files beginning with a period are hidden files, so make sure hidden files are visible if you do not see it.
If the file is missing, try saving your WordPress permalink settings first. If WordPress still cannot create it, you can create the file manually.
Still Unable to Save Changes?
If your WordPress or Divi editor still cannot save after restoring the .htaccess file, contact DataPacket Support.
Let us know the affected domain, the page you are trying to edit, and the error you receive when saving. A screenshot of the error can also help us find the problem faster.