Wordpress LScache Plugin: The manifest file isnt cacheable
Last Updated on: Wed, 15 Apr 2026 00:00:02 Id have preferred that this be done by the plugin but since its not, Im forced to add a line in the .htaccess file so that my JSON manifest file can be cached. I added this: ExpiresByType application/json A31557600. Wouldnt it be possible to add a function in the plugin or use a hook? json is a static source like CSS, Javascript and is not cachable by any HTTP cache. Static sources are cached by browser cache not by webserver/LScache plugin, but LiteSpeed webserver stores compressed static sources to deliver such sources faster to the client. In the WordPress back office, go to LiteSpeed Cache , then select Cache and click on the Browser tab. Enabling the browser cache adds a code area in the .htaccess file: marker BROWSER CACHE . What Im asking: is it possible to add the line of code that I indicated in my previous message in order to make the manifest file cacheable (by the browser)? Or, is it possible to provide a hook that would add this code? Such question is asked almost daily. Have you already heard about search function? https://wordpress.org/support/topic/manifest-not-caching/ Im sorry to annoy you but as you can see I considered your suggestion to add the code line in my .htaccess file. My question here concerns another subject: why not have it added by your plugin, following all those you create when activating the browser cache? Thus, json files will be treated by the browser cache just like other files. It was just a suggestion ? have a nice day. Refer to my first answer. json is a static source and static sources may not be cached because caching of static sources is already defined in HTTP protocol. Every browser can cache static sources, so why extra define in cache plugin? Im sincerely sorry because I dont practice good english (Im french) and maybe Im misunderstood. So if I may, heres a question: Do you think an image file or a pdf file or a text file are considered static sources already defined in HTTP protocol ? Best Regards, Do you think an image file or a pdf file or a text file are considered static sources already defined in HTTP protocol ? Yes! But you can control/modify how long static sources should be cached. https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Cache-Control https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Expires Well, and is that what is done by your plugin when the browser cache is enabled? This adds ExpiresByType directives in the htaccess file, is that correct? This is not my plugin. I am a user like you? json sources currently have no extra expires header in cache plugin, but should be added to the current defines. Thats why I linked to the post on the other site. Follow these instructions and you get everything you want. Im confused you arent the person I thought but thanks anyway for participating even though I dont know anything more than I already knew. My question is therefore unanswered and Im waiting for an intervention from a support team? Is it possible to add a ExpiresByType directive for json files in the htaccess file like those added by activating the browser cache ? You dont need a directive. You only have to add a header to define expire header for json in .htaccess. The answer you want to get is from plugin support: https://wordpress.org/support/topic/manifest-not-caching/ Hi, if a moderator goes through this, please delete this thread which doesnt add anything and is duplicated with another.
LiteCache Rush: Speed comes from using less, not from doing it faster
Reference