Flask - Python Web Framework

Flask is called a micro-framework; meaning that it only provides the absolute minimum requirements needed to get a web project up and running quickly, without any of the hassles of a more fully involved web framework.

Flask is written in Python and is based on Werkzeug and Jinja 2.

To get a Flask project started...

Easy setup:

>>> pip install Flask
>>> pip install Flask-Login

Flask Features

  1. Built in development server and debugger
  2. Integrated unit testing support
  3. RESTful request dispatching (bingo!)
  4. Uses Jinja2 templating
  5. Support for secure cookies (client side sessions)
  6. 100% WSGI 1.0 compliant
  7. Unicode based
  8. Extensively documented

Web development one drop at at time...

The Most Basic Flask Example:

from flask import Flask
app = Flask(__name__)

def hello_world():
    return 'Hello, Monty!'

if __name__ == '__main__':

A great example of the simplicity of Flask is a project called Flaskr

Craig Derington

Secular Humanist, Libertarian, FOSS Evangelist building Cloud Apps developed on Red Hat Enterprise Linux and Ubuntu Server. My toolset includes Python, Celery, Flask, Django, MySQL, MongoDB and Git.

comments powered by Disqus