About This Blog

Posted by
on under

I spent some of my spare time in the last month or so writing a tiny blog engine, and I really like how it came out.

Here are some interesting (to me, at least!) facts about my blog project:

  • Coded in Python.
  • Built on the Flask microframework.
  • A small sqlite database holds the posts and the comments.
  • The presentation of all pages and RSS feeds is driven by templates.
  • The comment form uses Google's reCAPTCHA to reduce spam.
  • The rendered HTML code of all posts, comments and sidebar sections is cached and only re-rendered when something changes.
  • A simple admin interface allows me to moderate comments and edit future posts.
  • Hosted on nginx web server.

I plan to write a series of articles to describe some of the above items in detail, so stay tuned for those.


  • #1 Chris Kavanagh said

    Thanks for the awesome tutorial on Flask! I hope you make some more tuts for other things as well. Maybe a Django tutorial, or antyhing in Python is great.

  • #2 qhz said

    thank for your article Miguel, I first to your website ,see you blog ,begin to study flask ,if meet problem ,I will sorry to bother you .....

  • #3 Juan said

    thanks thanks thanks for your awesome flask tutorial!

  • #4 dnk said

    Is there any chance you are going to update this for python3? I'm just starting out flask, and your tutorial looks like it is by far one of the best ones.... but I'm trying to use python3.

  • #5 Nick said

    Seems interesting, could you post the source code online (or email it to me)? I'd like to see it!

  • #6 John Godwin said

    Hello Miguel, I am very impressed with your website. The site is simple, concise, and does not have a lot of flashy glitter.

    My 12 year son wants to learn to start programming with Python and build his own website.

    We would like to order your book on "Web Development using Flask" and donate $50 to help you, How can we do this?

    Thank you

  • #7 Miguel Grinberg said

    @John: Thanks for your words. Unfortunately I don't have a way to take donations, but the intention is greatly appreciated!

  • #8 Maykel Moya said

    Hello Miguel

    This flask+sqlite is IMO a perfect balance between a bloated wordpress (like my blog) and a cool static blog that is dependent on external stuff for handling comments.

    Do you have plans to opensource the code running this blog?


  • #9 Aaron O'Neill said

    I have been working my way through your Flask Web Development book. For a tutorial, I have found it well structured and easy to follow. One of the best books on programming I have read. It has helped me at I learn web programming with Python. I am moving to Linux from Windows (so to Python from C#).

    As I was loading the packages, I saw that several were written by you. Thank you for your contributions.

  • #10 Jonathan said

    Thanks for the great Flask tutorial

  • #11 Shaun said

    Thanks for the tutorial on Flask.

  • #12 Pol Valter said

    This is the best Python / Flask blog I've ever read! Thanks, Miguel!

  • #13 Nelson Pedrozo said

    Hi Miguel,

    This small note is a "thank you" for writting a world-class tutorial for Flask. You did an amazing, throrough job in explaining everything, step-by-step. Really, top-level stuff. I'm glad I came across your blog while searching for Flask tools.


    Nelson Pedrozo

  • #14 Tuan said

    Hey Miguel

    First word, thank you for the interesting Mega-Tutorial, it is what I am looking for. I have a question: Can you use this same backend built from python-flask for Android application ?

  • #15 Miguel Grinberg said

    @Tuan: sure, the Android app sends HTTP requests to talk to the server, so it acts in the same way as a web browser.

  • #16 GULI said

    Hi~,I' beginner from China, is it OK to copy these articles and translate them and post on personal blog or a website , need any Authorization? Is it OK to reproduce without permission?

  • #17 Miguel Grinberg said

    @GULI: No, it is not okay to copy my articles and post them in other blogs.

  • #18 zahra said

    thanks! I do not know what should I do if you don't had this blog! It is very good and so helpful!

  • #19 Becky Brusky said


    I'm building my first async api based on your "Building Web APIs with Flask" on Safari books. Is there a way that the id used in the background method could be known by the process that will be run in the background?

    @app.route('/my_process/async', methods=['POST'])
    def my_process_async():
    do stuff, but can us id as a key in a database that stores the response to the request.

    Becky Brusky

  • #20 Miguel Grinberg said

    @Becky, not sure I understand your question. Where is the id coming from? If it comes from the request, then you can pass it to the background task as an argument, either explicitly, or by copying the entire request. If the id is a result of a new object inserted in the database, then the database provides the id right after the insert operation completes.