Cloudflare Pages で /foobar.html というファイルをデプロイした場合には /foobar でアクセスすることができる

結論

  • /foobar.html をデプロイしたとする
  • https://.../foobar.html にアクセスすると Webブラウザ のアドレスバーは https://.../foobar になり、正常にアクセスできる
  • https://.../foobar にアクセスすると正常にアクセスできる
  • つまり Cloudflare Pages では .html という拡張子は省略してアクセスできる

根拠

developers.cloudflare.com

If an HTML file is found with a matching path to the current route requested, Pages will serve it. Pages will also redirect HTML pages to their extension-less counterparts: for instance, /contact.html will be redirected to /contact, and /about/index.html will be redirected to /about/.

Powered by はてなブログ