Django vs Flask
Discussions comparing Django and Flask as Python web frameworks, debating their heavyweight vs lightweight approaches, suitability for beginners and projects, and alternatives like Rails or web2py.
Activity Over Time
Top Contributors
Keywords
Sample Comments
A lot of people will suggest Django, and it's definitely the most popular Python web framework (and therefore the most useful if you're looking for a job using one). However, Flask is written in a much more open-ended way that gives you a lot more power to create the structure of the application as you see fit. I've been working with it lately, and I'd suggest giving it a try.
I read in an answer of yours that you're learning Python. I learned Ruby myself with Rails in 2005 because I had no other reason to use Ruby back then. Rails was a much lighter framework than Django is now. I would recommend to start with something very lightweight, get the gist of it and move on to Web2py or Django.What you're looking for could be Flask or even something simpler like<a href="https://docs.python.org/2/library/simplehttpserver.html" rel="n
As someone who is thinking about doing a python project, should I learn Django or just go with Flask? Any thoughts on those two?
Since you mentioned Django, why not try out Flask?http://www.jeffknupp.com/blog/2014/01/18/python-and-flask-ar...
I've tried working with Django and it's always seemed much too heavyweight to me. Flask is my preferred web framework for Python; much easier for me to use and feels like it's helping me where needed and getting out of my way where needed, not weighing me down.
Isn't Django huge? And there's Flask as well.
And for anyone going down this path with Python, I recommend taking a look at web2py after Flask.web2py is where I finally settled after trying Django and Flask first. It's got more magic in it than Django, and yet, I found Django felt heavier and more "over-engineered". Flask, on the other hand, is very elegant, but as soon as you start patching together a few different libraries, the cognitive load of needing to understand Flask, WTForms and SQLAlchemy was too much for me.
Well... no thanks. I've been doing similar apps with Django and Flask. I'll take Django over Flask any day. Way too much fiddling with Flask.
I know you didn't list Python, but Django works very well. Bit of a learning curve though. Flask is a microframework (also Python), with emphasis on the micro.Django makes some trade-offs that might make it seem like you're less productive. Maybe it's true, but Django apps are very maintainable in my experience.
Try Rails and see. It's pretty impressive. Django is supposed to be pretty good too if Python is more your thing.