What You’ll Learn
- Why FS_METHOD matters for MainWP
- How to configure the setting
- How to troubleshoot file permission issues
Why This Setting Matters
WordPress can access the filesystem through several methods:
MainWP needs direct filesystem access to perform updates, install plugins/themes, and manage files efficiently. When WordPress uses FTP or SSH methods, MainWP operations may timeout or fail.
When You Need This Setting
Apply this setting if you experience:- MainWP Dashboard warnings about filesystem method
- Plugin or theme updates failing with permission errors
- Upload operations timing out
- “Could not create directory” errors during installations
How to Apply the Setting
1
Connect to your Child Site
Use FTP, SFTP, or your hosting file manager to access the site files.
2
Open wp-config.php
Locate and open the
wp-config.php file in the site root directory.3
Add the FS_METHOD constant
Add this line before the comment
/* That's all, stop editing! */:4
Save and test
Save the file and test by running an update from your MainWP Dashboard.
File Permissions
For direct filesystem access to work, WordPress needs proper file permissions:
If you’ve set FS_METHOD to direct but still encounter issues, check that your hosting account owns the files and directories.
Alternative: FTP Configuration
Some managed hosts don’t allow direct filesystem access. In those cases, configure FTP credentials instead:Troubleshooting
If setting FS_METHOD doesn’t resolve issues:- Verify file ownership matches your PHP process user
- Check if your host restricts certain PHP functions
- Review the Required PHP Functions list
- Contact your hosting support for assistance with file permissions
Self-Check Checklist
- FS_METHOD constant added to wp-config.php
- File saved successfully
- Test update runs without errors
- File permissions set correctly (755/644)
Related Resources
- Required PHP Functions - PHP requirements
- Resolve System Requirements - Server configuration
- Plugin Installation Fails - Upload troubleshooting
