Skip to content
This repository
tree: 6a781ce843
Fetching contributors…

Cannot retrieve contributors at this time

file 159 lines (99 sloc) 5.792 kb
layout title
default

About

web.py is a web framework for python that is as simple as it is powerful. web.py is in the public domain; you can use it for whatever purpose with absolutely no restrictions.

  import web

  urls = (
      '/(.*)', 'hello'
  )

  class hello:        
      def GET(self, name):
          i = web.input(times=1)
          if not name: name = 'world'
          for c in xrange(int(i.times)): print 'Hello,', name+'!'

  if __name__ == "__main__": web.run(urls, globals())

A complete web.py application

Get Started

web.py 0.21 was released 2007-05-28: web.py-0.21.tar.gz

To always have the latest version of web.py, run:

svn co http://webpy.org/svn/trunk/web/

Upgrading from an older version? Be sure to read the upgrade guide.

Who uses web.py?

reddit mascot

reddit.com, one of the top 1000 sites according to Alexa, uses web.py to serve its millions of daily page views. "It's the anti-framework framework. web.py doesn't get in your way," explains founder Steve Huffman. (Disclosure: web.py creator Aaron Swartz was also a founder of reddit.)

Yandex, a Russian traffic provider whose homepage alone receives 70 million daily page views, uses web.py for certain projects.

LShift has used web.py to build websites for Expro and publisher Dorling Kindersley. "web.py allows us to do what we do best," they report. "It does the webapp thing brilliantly, and without requiring us to compromise on flexibility and originality."

Buzz

"We completed our server rewrite a few days ago with web.py and it was everything we could have wished for."

"Django lets you write web apps in Django. TurboGears lets you write web apps in TurboGears. Web.py lets you write web apps in Python."

  • Adam Atlas

"very nicely written and concise (not to mention it's written by Aaron Swartz, whose coding skills are very trustable), and doesn't get in my way"

  • Jonas Galvez, Blogamundo #

"the first framework ... where I could just scribble code and see something working without even having to try to understand the logic of it. A pleasure to integrate."

"Guido [van Rossum, creator of Python], you'll probably find that web.py best suits your style. ... If you don't like it, I can't imagine which of the other dozens of frameworks out there you would like."

  • Phillip J. Eby, creator of the Python Web Server Gateway Interface (WSGI) #

"... the [Cheetah] example I saw on web.py looks "right". (web.py itself OTOH gets an "F", for undocumented code with too much magic behavior. upvars(), bah.)"

  • Guido van Rossum, creator of Python #

"suffice to say I think Aaron is headed in the right direction."

"a very fascinating moment for me. The feelings just like the first time I wrote my php script ... it sure have let me learn python in the fun way. Good work aaron !"

web.py documentation:

web.py community

  • mail list: home of the web.py discussion

  • irc channel: home of the web.py talk

web.py development:

Something went wrong with that request. Please try again.