انتقل إلى المحتوى

الدروس استكشاف الأخطاء وإصلاحها مبتدئ1 دقائق قراءة

How to Fix a 403 Forbidden Error

A 403 Forbidden error means the server refuses to show a page. Fix wrong file permissions, missing index files, .htaccess rules and security blocks.

بواسطة فريق تحرير ZSOLNET آخر تحديث

هذه الصفحة غير متاحة بالعربية بعد، لذا تُعرض بالإنجليزية.

أهم النقاط

  • Most 403s come from missing index files, wrong permissions or .htaccess rules.
  • Use 755 for folders and 644 for files; never 777.
  • Firewalls and security plugins can block individual requests — check their logs.

A 403 Forbidden response means the server understood the request but refuses to fulfil it. Usually that’s a permissions or configuration problem rather than a real security decision.

Common causes and fixes

Missing index file

If a folder has no index.html or index.php and directory listing is disabled, the server returns 403. Make sure your home page file is in the domain’s document root (often public_html) and named correctly.

Wrong file permissions

The web server must be able to read your files.

ItemTypical permission
Folders755
Files644
wp-config.php600 or 640

In cPanel’s File Manager, right-click a file and choose Change Permissions. Avoid 777 — many servers block it.

.htaccess rules

Deny from all, Require all denied or IP restrictions in .htaccess block access. Rename the file temporarily to test, then fix the rule that blocks you.

Security tools

A web application firewall (such as ModSecurity) or a security plugin may block a request it considers suspicious — for example a form submission containing code. Check your security plugin’s log, or ask your host which rule matched.

If only certain visitors see the 403, check for hotlink protection, IP blocks or geo-blocking in cPanel or your CDN.

شارك X LinkedIn Facebook

الدخول إلى حسابك

أدِر نطاقاتك واستضافتك وفواتيرك من مكان واحد.

اتصال آمن مباشرة مع منطقة العملاء في ZSOLNET.

افتح لوحة تحكم ZSOLNET

ليس لديك حساب؟