Help with fixing 404 error when redirecting to HTTPS

Hello guys, I have an app deployed with Heroku with a custom domain name. I am using Cloudflare for an SSL certificate, and I have enabled a rule to proxy HTTP requests to HTTPS. However, it seems all my route paths to my backend are getting rewritten to /api/route instead of /route, which is causing 404 errors on all my requests. This isn’t an issue when I turn off the proxy. So my question is, are these path rewrites normal or expected behavior when proxying HTTP to HTTPS, and I should rewrite all my routes to include /api, or is there something wrong with my configuration?

Thank you in advance!

Might be this :point_up:

Furthermore, despite Heroku app, may I ask if you are using Cloudflare Workers too for your domain and some path(s), or not? :thinking:

Hi, no I am not, and I am relatively new to this so I’m not too familiar with that concept. Can you explain what Cloudflare Workers are and how I can integrate them, or point me in the right direction? Thank you in advance!

This topic was automatically closed 15 days after the last reply. New replies are no longer allowed.