Take the 2-minute tour ×
Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

I've set up a Ubuntu server with Apache 2. Instead of FTP I'm using WebDAV upload/download files. Works great. But it is not possible to upload/download or modify .htaccess files, because the Apache server returns an 404 (forbidden) error.

How is it possible to enable working with .htaccess files like with any other file?

By the way: Don't worry. The WebDAV access run over a WebDAV-only host to avoid security issues.

Best regards, Bernd

share|improve this question

3 Answers 3

You can't access .htaccess or .htpasswd from a normal apache because it protects them. They have sensitive information inside (usernames, special commands, etc) and it correctly does not allow you to see them.

(s)ftp is the way to do it...

If you still want to edit them...try changing this config part inside your /etc/apache2/apache2.conf:

AccessFileName .htaccess

<Files ~ "^\.ht">
    Order allow,deny
    Deny from all


Deny from all


Allow from 
Deny from all

to allow your internal network clients to access these files...

share|improve this answer
Cool. It works. Thank you. –  Bernd Aug 28 '09 at 13:03

For completeness, one possible resolution would be switching to svnserve, Subversion's native server, if it's practical to do such a thing.

share|improve this answer

what about disabling .htaccess files with

  <Directory DocumentRoot>
      # disable the .htaccess redirect in /var/www/.htaccess
      # AllowOv. only valid in <Dir > tag!
      AllowOverride None
      Order allow,deny
      allow from all                        
share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.