I am getting an nginx 404 on all pages ending in .html in my test instance, which is in a subdirectory at the root of production. For instance, /test/, /test/contact/ and /test/about-us/ are all good. But /test/women.html, /test/solar-jacket.html, and /test/men.html all return 404. So, no category or product pages. :-( It's the same issue with or without rewrites.

This issue is only on my default store. A second store running on a subdomain has no problem displaying the same product pages.

Edit: It's a problem with ".html". If I enter a bad URL without ".html", I get a Magento 404. All URLs that end with ".html" return nginx 404.

  • try to disable url_rewrite and then flush cache. Hope it will work.
    – Manish Joy
    Commented Feb 4, 2017 at 5:04
  • Same issue with or without rewrites.
    – Joe Palaca
    Commented Feb 4, 2017 at 7:08
  • Do you have a folder in your project root named "test"? Commented Feb 4, 2017 at 7:47
  • what happens when you disable html suffixes? Commented Feb 4, 2017 at 11:09
  • @ArjenMiedema Yes, my testing instance is in a folder in root named "test" with an exact copy of root.
    – Joe Palaca
    Commented Feb 7, 2017 at 21:27

1 Answer 1


Remove .html suffix from using admin panel.

Go to Admin -> Stores -> Configuration -> Catalog -> Catalog

In Search Engine Optimisation Section:

Remove the value from text-field inside Product URL Suffix. Do the same for category view.

Re-index the site and clean the cache:

php bin/magento indexer:reindex
php bin/magento cache:flush

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.