DEV Community

Cover image for HOW TO HOST YOUR STATIC WEBSITE ON CloudflarePAGES
adebytes
adebytes

Posted on

2

HOW TO HOST YOUR STATIC WEBSITE ON CloudflarePAGES

Hey budding web developer transitioning into the world of codes and bugs. You have probably spent a considerable amount of time perfecting your skills through markup and programming languages, and now you have built a website that you are eager to show to your group or use as part of a portfolio. You have built it on your system or device, so what’s left is to put it up somewhere. There are different free sites where one can deploy a static web from GitHub pages, Netlify, and CloudfarePages. I choose CloudfarePages because of its simple approach for newbies using HTML, CSS, and JavaScript bits. However, it should be noted that to deploy your site on Cloudfare as with most other static site deployments, you will have to create a Github repository where you upload the files of your web design. You can sign up to cloudfarepages on https://dash.cloudflare.com. On your dashboard, select Workers & Pages > Create application > pages > connect to git. Then, Select the new GitHub repository that you created and, in the Setup builds and deployments section, provide the following information:

Framework Preset None

Production branch main
Build command (leave empty if there are none use *JEKEYLL BUILD)
Build output directory (can be “/_SITE”)

After you have finished setting your build configuration, select Save and Deploy. Your project build logs will be output as Cloudflare Pages installs your project dependencies, builds the project, and deploys it to Cloudflare’s global network.

Sentry blog image

How to reduce TTFB

In the past few years in the web dev world, we’ve seen a significant push towards rendering our websites on the server. Doing so is better for SEO and performs better on low-powered devices, but one thing we had to sacrifice is TTFB.

In this article, we’ll see how we can identify what makes our TTFB high so we can fix it.

Read more

Top comments (0)

A Workflow Copilot. Tailored to You.

Pieces.app image

Our desktop app, with its intelligent copilot, streamlines coding by generating snippets, extracting code from screenshots, and accelerating problem-solving.

Read the docs

👋 Kindness is contagious

Please leave a ❤️ or a friendly comment on this post if you found it helpful!

Okay