How can I use an .htaccess file in Nginx?

Nginx doesn’t support .htaccess (see here: “You can’t do this. You shouldn’t. If you need .htaccess, you’re probably doing it wrong.”).

You’ve two choices (as I know):

  • import your .htaccess to nginx.conf (maybe the htaccess to nginx converter helps you)
  • use authd-htpasswd (I didn’t try it)

Leave a Comment

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)