I understand that .htaccess
is not supported by GitHub Pages. Is there an alternative for password-protecting particular directories for websites hosted by GitHub Pages?
It is now possible to completely bypass Jekyll processing on GitHub Pages by creating a file named . nojekyll in the root of your pages repo and pushing it to GitHub.… It is now possible to completely bypass Jekyll processing on GitHub Pages by creating a file named .
GitHub Pages is a static site hosting service that takes HTML, CSS, and JavaScript files straight from a repository on GitHub, optionally runs the files through a build process, and publishes a website.
About HTTPS and GitHub PagesAll GitHub Pages sites, including sites that are correctly configured with a custom domain, support HTTPS and HTTPS enforcement.
Although you can't use .htaccess
or .conf
, Github has instructions on how to use the Jekyll Redirect From plugin.
https://help.github.com/articles/redirects-on-github-pages/
The page above no longer has any mention of the plugin. The direct link to the jekyll-redirect-from plugin GitHub repo is https://github.com/jekyll/jekyll-redirect-from
"Unfortunately, GitHub pages only supports static pages. There is no way to make it execute server-side code and thus it's impossible to protect your pages with any kind of authentication scheme. If you expand further on why you need to password-protect your pages, maybe I can help you find a workaround."
Source: https://webapps.stackexchange.com/questions/35692/is-there-an-alternative-to-using-htaccess-to-password-protect-subdirectories-in
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With