Deploying Bolt.diy with Cloudflare Pages (the easy way!)

Great job. I just didn’t have the time today to make instructions. Love it.

I kind of just played around with it myself until I got it the way I wanted. Pretty cool through and you can customize the landing page too!

You are amazing. Your tutorial really helps beginners like myself. Thank you very much.

1 Like

Thanks, I appreciate it. I’ll probably be taking feedback and lessons learned from this thread to create an official wiki/docs. Hope it helped!

Im still facing this issue no matter what. ENV File has been updated. Using Claude.

1 Like

I’m not sure this belongs here. This thread is about deploying Bolt.diy with Cloudflare Pages, which has nothing to do with the .env file. But I did mention this in response to a question by @MotionNinja. Please follow the instructions per comment #39 and refer to Cole’s Guide.

But did you rename the .env.example to .env.local and make sure the endpoints were working? I would test a HuggingFace API key because they don’t require setting up payment methods like other do, and they’re free. Also, make sure to pull the “stable” branch (not “main”) as some people have been experiencing issues with it.


Bonjour et grand merci. J’ai suivi pas à pas votre procédure. J’ai un problème d’affichage (voir image). J’utilise bien pnpm run build et j’ai fait un **“Retry deployment” **. Merci d’avance pour votre aide.

Hi @kricalens,

please write in english :slight_smile:

2 Likes

Sorry ! :face_with_hand_over_mouth: I thought the translation would be automatic ! Here it is :wink:
Hello and many thanks. I followed your procedure step by step. I have a display problem (see image). I use pnpm run build and I did a **“Retry deployment” **. Thank you in advance for your help.

Thanks :slight_smile:

Are you on the “stable” branch? In the main branch there is, I guess still, a problem for some users not displaying properly. The Core-Team is working on that.

Edit => If you need further help, create your own topic, so we can keep this clean and seperated.


Yes I am !

switch to “stable”- Branch and try again

1 Like

OK thanks. I don’t have any other possible switch. I won’t bother you anymore. I will try to find

Dont know what you mean with switch, but the community is here to help.

Just open your own topic and we can investigate/try to fix there

=> Open “New Topic” top right
=> You can reference to this chat with this link: Deploying Bolt.diy with Cloudflare Pages (the easy way!) - #67 by kricalens

1 Like

The tutorial was created when main was the “stable” branch, so it needs to be updated and/or a Troubleshooting guide added.

Go to Cloudflare → Workers & Pages
image

Click on your deployment, then Settings Tab:

Scroll to “Branch Control” and click Edit:

Switch to “stable”

And click “Save”

2024-12-27T23:05:47.288613Z Cloning repository…
2024-12-27T23:05:47.948318Z From GitHub - PenguPoop/bolt.diy: Prompt, run, edit, and deploy full-stack web applications using any LLM you want!
2024-12-27T23:05:47.948717Z * branch 4844db82fad65c79e17e89724775ace380ab54a1 → FETCH_HEAD
2024-12-27T23:05:47.948824Z
2024-12-27T23:05:47.992077Z HEAD is now at 4844db8 ci: improved change-log generation script and cleaner release ci action (#896)
2024-12-27T23:05:47.992377Z
2024-12-27T23:05:48.065152Z
2024-12-27T23:05:48.065516Z Using v2 root directory strategy
2024-12-27T23:05:48.086178Z Success: Finished cloning repository files
2024-12-27T23:05:49.681561Z Checking for configuration in a Wrangler configuration file (BETA)
2024-12-27T23:05:49.682321Z
2024-12-27T23:05:49.683041Z Found wrangler.toml file. Reading build configuration…
2024-12-27T23:05:49.688698Z pages_build_output_dir: build/client
2024-12-27T23:05:49.68889Z Build environment variables: (none found)
2024-12-27T23:05:49.780613Z Successfully read wrangler.toml file.
2024-12-27T23:05:49.92346Z Found a .tool-versions file in user-specified root directory. Installing dependencies.
2024-12-27T23:05:50.373802Z pnpm plugin is not installed
2024-12-27T23:05:50.376458Z Error: Exit with error code: 1
2024-12-27T23:05:50.376609Z at ChildProcess. (/snapshot/dist/run-build.js)
2024-12-27T23:05:50.37672Z at Object.onceWrapper (node:events:652:26)
2024-12-27T23:05:50.376849Z at ChildProcess.emit (node:events:537:28)
2024-12-27T23:05:50.377058Z at ChildProcess._handle.onexit (node:internal/child_process:291:12)
2024-12-27T23:05:50.383235Z Failed: build command exited with code: 1
2024-12-27T23:05:51.084917Z Failed: error occurred while running build command

any idea, why mine won’t deploy?
I did everything on stable branch

is pnpm installed? :slight_smile:

Screenshot in step “7. Click the “Setup and Deploy” button”

Hi,

I’m experiencing a significant slowdown in my browser while trying to launch Bolt.diy locally. So, I’ve switched to using the Cloudflare method But even on Cloudflare pages it feels so heavy, and when it is installing packages, it feels like they’re being installed in my local browser’s cached data

Could you please advise me

@Cyril-777 It doesnt matter where you host bolt.diy. The Webcontainer within bolt is always running client side as far as I know, thats why the tab also consumes a lot of memory.
I guess you maybe do not have enough memory free?

3 Likes

Must i fill all the API keys in order for the deployment to work

1 Like

Nope, you don’t have to put any. Back when you did, I would just put dummy ones when deploying it publicly.