r/apache

▲ 2 r/apache+2 crossposts

I built a free visual .htaccess generator because I was tired of Googling Apache directives

Hey everyone,

Like most of you, every time I needed to set up redirects, force HTTPS, add security headers, or configure caching in .htaccess, I'd end up with 15 tabs open copy-pasting snippets and hoping nothing breaks.

So I built GetHtaccess, a simple visual tool where you just pick what you need, configure it through a clean UI, and get your .htaccess file ready to download or copy.

🔗 https://gethtaccess.com

What it does?

  • Pick from common rule types (redirects, rewrites, force HTTPS, security headers, caching, gzip, CORS, hotlink protection, block IPs, custom error pages, etc.)
  • Configure each rule visually without need to remember Apache syntax
  • Stack multiple rules, reorder or remove them
  • Copy or download the final .htaccess file

You can also paste an existing .htaccess and it parses it into editable rules

No signup, no login, no ads, no tracking. Not monetized in any way

I built this purely because I kept running into the same problem and figured others do too. It's as straightforward as I could make it, dark UI, works on mobile, zero friction.

Would love to hear feedback or suggestions for rule types I might have missed.

Cheers!

reddit.com
u/PolitiaGramaticala — 8 hours ago
▲ 4 r/apache+1 crossposts

.htaccess help!

I'm moving content from an old domain to a new one, but with a few catches. I want the home page from the old domain to go to a specific page on the new domain. And I want everything from a specific folder on the old domain to go to a new subdomain. I want pages and querystrings to convey too so the person who visits site A almost doesn't notice that they have been forwarded to site B.

Everying else can forward as it (and I have that part figured out!)

I have tried a ton of different ideas and none have worked so I'm running out of options. Here is what I have, or mostly want:

<IfModule mod_rewrite.c>

RewriteEngine On

# If / or /index.php redirect to newsite.org/index-alt.php (then stop! [END])
# the first challenge

# If /directory[/whatever] redirect to subdomain.newsite.org[/whatever] (then stop! [END])
# the second challenge

# Or redirect everything else to newsite.org[/everythingelse?etc]
# this works but is it the best solution?

RewriteRule .* https://newsite.org%{REQUEST\_URI} [R=302,L]

</IfModule>

reddit.com
u/blargy-blargy — 1 day ago