To perform the requested action, WordPress needs to access your web server. Please enter your FTP credentials to proceed
WordPress can’t write directly to its files (ownership differs from the PHP user), so it falls back to asking for FTP details.
Seen on:
WordPress
Meaning
WordPress uses the “direct” method only if files are owned by the PHP process user. On self-managed servers fix ownership; FS_METHOD direct forces it but still needs write permission.
Common causes
- WordPress files owned by a different user than PHP-FPM/Apache
- Mixed ownership after manual uploads
- Shared hosting setups requiring FTP
⚡ Quick fix
- chown the WordPress directory to the PHP user
- Optionally define('FS_METHOD', 'direct') once permissions are right
Detailed fix by platform
WordPress
- php
// wp-config.php (after fixing ownership) define('FS_METHOD', 'direct');
Linux
- bash
ps -o user= -C php-fpm8.3 | head -1 # PHP user sudo chown -R www-data:www-data /var/www/html
How to diagnose
- PHP user — Process owner
- Files — ls -l wp-content
🔧 Still not fixed?
Many errors look alike. If the steps above didn’t solve it, one of these is probably what you’re facing:
Similar errors
- Call to undefined function (WordPress) WordPress: Fatal error: Uncaught Error: Call to undefined function wp_get_current_user() / add_action() / get_header()
- Call to undefined function create_function() WordPress on PHP 8: Fatal error: Uncaught Error: Call to undefined function create_function() / each()
- Critical error WordPress: There Has Been a Critical Error on This Website
Most viewed in WordPress
Other ways to find it
🧠 Still stuck? Analyze your error
Paste the full message, response headers or stack trace — we'll detect the platform and point to the most likely cause.
Was this page helpful?
Report a correction or suggest an improvement
Last updated 7 Oct 2026