Cloudflare Developers

CD

Cloudflare Developers

Welcome to the official Cloudflare Developers server. Here you can ask for help and stay updated with the latest news

Join

Doc: Add a custom domain to a branch. Not working.

Link: https://developers.cloudflare.com/pages/how-to/custom-branch-aliases/ When I find CNAME record with the name staging and change the target to include your branch alias. (mydomain.com -> staging.mydomain.com)...

Serverside Rendering

I'm trying to only use Clientside Rendering, yet something is using SSR on my Cloudflare Pages. How can I find out what?
No description

How can I disable redirection from http to https?

I'm serving a web app which needs to access gadgets/devices in the local network (private IP address space). There's no DNS resolution which means there's also no SSL possible and browsers are rejecting non-ssl connections when the original content is served via ssl. That's why I need to disable the automatic redirection to https. How can this be done with CloudFlare Pages? Thanks...

NextJS deployment fails after adding D1 binding

domain: next-on-cloudflare-boy.pages.dev deploymentId: 6e079786-4d28-4262-83a0-e14280c26198 accountId: b26f727ceebb9fef992e39350f2828e6 I have barebones @cloudflare/next-on-pages setup (from npm create cloudflare@latest) and deployment was working fine until I added D1 binding....

What i18n libraries work with next-on-pages?

Our company's project is using Next.js and we want to migrate this to the edge using next-on-pages. At the moment we use next-i18next package for the translations, but it seems to be incompatible with the next-on-pages environment requirements. What are our options here for i18n?

MIME type issues with functions?

Refused to execute script from 'https://example.com/myfunction.js' because its MIME type ('text/html') is not executable, and strict MIME type checking is enabled. CODE: ```HTML <!DOCTYPE html> <html>...

Are mTLS bindings supported on Pages Functions yet?

I have been using mTLS bindings on vanilla Workers successfully (thanks!) and I now have a Next.js app I was writing a Route Handler for, using the Edge Runtime mode. I was hoping to use an mTLS binding to do a fetch but browsing the docs, I didn't see mTLS bindings mentioned here: https://developers.cloudflare.com/pages/platform/functions/bindings/ I can solve this using a Service Binding and separating the deployment but was hoping mTLS bindings were available for Pages Functions too since that would simplify the code....

Show visitor count on my cloudflare page

Hello, I have a cloudflare worker https://live.lofi.radio/ which shows: 20 I want with HTML/Javascript show this number on https:lofi.radio But I get this error:...

Deploy hooks - preview branches

I am not sure what could be a reason but I do not see a different branch than main (production) when configuring a deploy hook. Is it possible to have a deploy hook for a different branch?

How can i use d1 locally(for test) on sveltekit?

I use sveltekit on cloudflare(with cloudflare adapter). Recently i fall in love on cloudflare serverless echo system. I want to test my code on dev mode but evnet.platform is always undefined. run script: npx wrangler pages dev --local --d1=DB -- npm run dev...

pages help

Custom domain gives connection timed out, host error

Yarn workspace monorepo not building on pages

Any idea why the build fails? I've tried numerous combinations for the build configs and can't seem to get it to work

Getting strange SSL errors when connecting to Cloudflare Pages site

We see a small percentage of our users running into SSL issues when connecting to app.skiff.com which runs on Cloudflare Pages. The underlying TLS error is * error:1400410B:SSL routines:CONNECT_CR_SRVR_HELLO:wrong version number The really strange part is that the SSL connection goes away when they move off of wifi and onto their 4g/5g connection. This was true for an Android device connecting to the Haifa data center....

Struggling to get Durable Objects to work with pages

I am building a pages app using the Vue template. So far I have gotten Functions, KV, and R2 to work, now I am trying to add Durable Objects, but I can access them from the Function. I get [wrangler] Couldn't find wrangler dev session for class "DurObj" to proxy to So how do I get the durable object to run locally?

Node not downloading in pages builds

For the past couple of days many deployments get stuck in the "Downloading node" stage. ``` 16:02:16.380 Success: Finished cloning repository files 16:02:17.001 Installing dependencies...

Custom domain - (partial CNAME setup)

Hi, I want to use a custom domain with my pages app, the issue is I cannot have the nameservers on the CF account they need to be held on a different CF account. Suggested solution is to use a partial CNAME setup: https://developers.cloudflare.com/dns/zone-setups/partial-setup/setup/...

308 redirects for paths without trailing slash

Have followed discussion on the thread - https://community.cloudflare.com/t/cloudflare-pages-get-rid-of-redundat-308-redirect/324582 Is there any solution without adding functions for this, it affects page indexing in google search console. I am using this workaround atm - https://community.cloudflare.com/t/cloudflare-pages-disable-non-trailing-slash-308-redirect/316995/7...

Analytics - status code and always online

In the description of the Web Analytics feature it says that I can "See visits, page views, requests, status codes, and more across all your project’s domains" but when I go to the analytics I can't see the status code. On a similar topic - how can I see the stats regarding cases of visitors seeing the top banner that says "This website ..... is currently offline. Cloudflare's Always Online shows a snapshot of this web page from the Internet Archive's Wayback Machine. To check for the live version, click Refresh"? Not that I understand how can it really happen when the website is hosted by cloudflare pages.......

/functions directory alternative?

If I compare the two cloudflare adapters side-by-side I can see that the adapter-cloudflare (https://kit.svelte.dev/docs/adapter-cloudflare#comparisons) should be enough since Functions is a part of Cloudflare Pages. But it seems we need to have the /functions directory at the root level of the project. I’m wondering whether that is always true or whether there is an exception for Sveltekit. "As long as your directory follows the proper structure, Pages will identify and deploy your functions to our network with your site."...

Requests suddenly having no headers

Hello, I'm working on some functions that read a specific header, and I'm suddenly realizing that no headers are getting to my code. This was working fine earlier, and it's just suddenly not and I'm not sure what has changed I should note I'm using SvelteKit, but afaik SvelteKit doesnt change the actual request object in any way...