Lucee Not Reading htaccess File for SES Urls

I recently installed Lucee on Windows using the installer “lucee-” and am testing a website that previously ran using Coldfusion.

Everything works well, except that the htaccess file isn’t being read, which handles the Search Engine Safe (SES) Urls. Previously the URL would translate to using the htaccess rule:

RewriteRule ^([A-Za-z0-9-]+)/?$ index.cfm?do=$1 [NC,L]

Currently, if I run, it gives the error

HTTP Status 404 – Not Found
Type Status Report
Message The requested resource [/mywebsite/profiles] is not available
Description The origin server did not find a current representation for the target resource or is not willing to disclose that one exists.
Apache Tomcat/9.0.86

However, if I run the page it does work as expected.

This leads me to believe that the htaccess file isn’t being read/seen. I have tested this by adding some garbage to the htaccess file to see if it would cause the website to error, but it does not. So this file appears to be being ignored/bypassed.

Is there anything else I have to do since installing Lucee to get this to work properly? At my Lucee webhost (Vivio), the htaccess file is detected and works perfectly. So it’s just my local machine with this new installation of Lucee that seems to missing something. I checked the docs at: Configuring SES URL's on Windows OS's :: Lucee Documentation but this only seems to apply to older versions of Lucee.

So I’m not sure where to go from here. Any help would be appreciated.

OS: Windows 10 (10)
Java Version: 11.0.22
Tomcat Version: 9.0.86
Lucee Version:

Yes, .htaccess are Apache Web Server files, not Tomcat.

If you want to continue using Tomcat as rewrite engine, you should use Tuckey URLRewriteFilter addon.

Here is the documentation:

It’s quite simple to set up.

If you have problems, ask again.


1 Like

Thanks. The download link appears to be down. Does it work for you?

Doesn’t work for me. Same error that I posted a screenshot of above.

Could be, you…

1 Like

Your link worked just fine. Thank you! Not sure why the original link doesn’t. I’ve tried turning off VPN and using different PCs to no avail.

I’m following the installation instructions. As soon as I add the FILTER code to the web.xml file, the website and Lucee admin break with the message below. I would expect that my website and the Lucee admin websites should still run as normal after adding the Filter. If I remove the code from the web.xml file, it runs as per normal again. So something about this is breaking the normal processing of the websites. Any ideas? Thanks

" HTTP Status 404 – Not Found

Type Status Report
Description The origin server did not find a current representation for the target resource or is not willing to disclose that one exists.

Apache Tomcat/9.0.86"

This is the code:


this file exists?

It does. If I include it in the WEB-INF folder, this is the error I get:

The reason for this error is because the path it’s trying to access is this:
but should be this:

I’m not sure how it’s getting that extra “ROOT” part.
The same happens if I try and access the website:
Page /hugirls/index.cfm [C:\lucee\tomcat\webapps\ROOT\hugirls\index.cfm] not found

Maybe the urlrewrite file is causing this, but I would expect it not to break the website or Lucee admin.

This is the contents of the urlrewrite file based on the docs that I got it from:

<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE urlrewrite PUBLIC "-// UrlRewrite 5.0//EN"


    Configuration file for UrlRewriteFilter


            The rule means that requests to /test/status/ will be redirected to /rewrite-status
            the url will be rewritten.
        <to type="redirect">%{context-path}/rewrite-status</to>

            The outbound-rule specifies that when response.encodeURL is called (if you are using JSTL c:url)
            the url /rewrite-status will be rewritten to /test/status/.

            The above rule and this outbound-rule means that end users should never see the
            url /rewrite-status only /test/status/ both in thier location bar and in hyperlinks
            in your pages.


I strongly suspect that you need to add a Tomcat context directive with the value path=“hugirls” to your setup. Where to add it, depends on your setup. That would be through server.xml (old style) or adding a tomcat context file to /pathToLucee/tomcat/config/catalina/domain-name-,of-your-site/hugirls.xml.

Could you please elaborate on this. I have zero experience with Tomcat and was simply looking for a “simple” way to get SES Friendly urls to work, which is turning out not to be the case with this plugin.


  1. Backup everything so you can always rolback.
  2. Open Tomcats server.xml.
  3. Find the Host entry that is setup for running your site.
  4. Add the context like so:
<Host ...>
    <Context path="/hugirls" docBase="/path/to/your/cfmfiles" />
    <!-- Other contexts or default context --

Th en restart Tomcat

Thanks andreas, but that didn’t work. The same error as before occurs. (see the yellow lucee dump above)

@ Roberto_Marzialetti Would you mind stepping in and helping here please. You suggested the tag, so you may know why it isn’t working.

check the permissions on the added / changed files and file paths.

ls -lt