Websites in Python

Want to build websites using Python? Didn't know that was possible? In this blog, we explore your options—and share the tool of choice we use at Aspire Coding Academy: Flask.

Aren’t Websites Built Using HTML and CSS? 🙋

Yes—but that’s only part of the story. HTML and CSS make up the front end of a website: what users see and interact with. Sometimes, the front end is all you need.

However, if your website needs server logic—like user logins or connecting to a database, you’ll need a backend server to handle that logic.

There exist of course, backend camps supporting all different languages. In recent history JS based stacks like MERN have been the most "hyped". Unbeknownst to some, Python has become increasingly popular as well. In our opinion, if you started learning coding in Python, like many do, there is little reason not to stick with Python when moving to web development.

Which Web Framework Should I Use? 🔨

There are several Python web frameworks: Flask, Django, and FastAPI, to name a few. So how do you choose?

Here’s our simple advice when selecting frameworks. And this applies to any technology, not just web development.

  1. If you're working with existing software, like at a company, stick with what’s already being used.
  2. Choose something you could pick up easily. For example, while Django is a robust Python web framework, it's often more advanced, so it may not be the best first choice unless you are already proficient in web applications.
  3. Choose tools that are well maintained and have strong community support—beginners often overlook this, but any seasoned programmer will tell you how much of a difference this makes.

Why We Use Flask 🫙

No, we’re not die hard Flask fans. But this is why it made sense for us.

  1. Our core starting curriculum is in Python and Flask was the most light weight option to extend from our back end applications into full stack.
  2. At ACA we focus on fundamentals and extension into real world applications. We minimize the friction needed to go from step 1 to step 2. Flask, in our opinion, offers a smoother runway from first exposure to a final product compared to other frameworks.
  3. Most of the popular Python frameworks are well supported. Flask also clears this bar.

For educational purposes, it strikes the right balance between power and simplicity.

Questions?

Contact us below! We’re happy to discuss all things software. Follow us on LinkedIn for updates on new blog posts.

Next
Next

What is Git?