New Early adopter or innovator? InfoQ has been working on some new features for you. Learn more

Learning Ruby on Rails with Michael Hartl

| Posted by Robert Bazinet on Apr 12, 2011. Estimated reading time: 6 minutes |

Learning a new programming language can be a daunting task and at times difficult to know where to start.  Now try to learn a new web framework at the same time and you have a recipe for confusion.

Ruby is a programming language created in the mid-90's but gaining in popularity daily.  Ruby on Rails is a term we seem to hear daily now with more and more companies adopting it to create web applications in less time with less ceremony.

Where does one start to learn a foreign programming language and a foreign web framework?  There are a number of great books out there, some starter books but others more advanced.

One resource for Java and .NET developers or anyone wanting to get started with Ruby on Rails 3 is  This site created by Rubyist Michael Hartl, is a destination with the Ruby novice in mind.  Whether you learn best by reading a book or watching videos, Michael offers both.

InfoQ had the opportunity to talk with Michael about his approach to teaching people Ruby on Rails. His book, the Ruby on Rails 3 Tutorial, from which he was kind enough to provide Chapter 8 of the book titled "Sign up".  This chapter guides the developer along the path of creating a user sign up page for their Rails application.

Robert Bazinet (RB): Who are you and tell me a bit about your background?

Michael Hartl (MH): I'm a programmer, educator, and entrepreneur. I coauthored RailsSpace, a best-selling Rails tutorial book published in 2007, and was cofounder and lead developer of Insoshi, a popular social networking platform in Ruby on Rails. Previously, I taught theoretical and computational physics at the California Institute of Technology (Caltech), and in 2008 I participated in the Y-Combinator entrepreneur program.

RB: What is the Ruby on Rails 3 Tutorial book?

MH: The Ruby on Rails 3 Tutorial book teaches how to develop and deploy real, industrial-strength web applications with Ruby on Rails, the open-source web framework that powers many of the web's top sites,including Twitter, Hulu, and the Yellow Pages.

RB: What type of developer should read this book?

MH: The book is suitable for anyone interested in learning web development with Ruby on Rails.

RB: I see you also provide a video tutorial series for Rails 3 as well.  Is this companion content for the book or completely separate material than the book?  What will people find different about the videos than the book?

MH: The screencasts follow the book for the most part, but the screencast format leads to a very different and complementary learning experience. It's similar to the difference between a book and a movie based on the book.

RB: The site allows readers to view the entire contents of the book for free; What is the purpose of providing this free content?

MH: The free content is a business strategy. It leads to inbound links, good search engine placement, lots of referrals, and tons of good karma.

RB: Do you think Rails 3 is a lot better than Rails 2.3 for new developers coming to the framework?

MH: The internals of Rails 3 are significantly cleaner than those of Rails 2.3, but for the typical developer I don't think the difference is all that large. The biggest difference is that the Rails 3 public API is now stable by design, so Rails 3 will be easier on newbies as we move forward because fewer things will break from one release to the next.

RB: What is the best approach for an experienced programmer to learn Rails and bring the framework into use at their company?

MH: In terms of selling the framework internally, I'd suggest pointing to the many successful websites using Rails. As far as learning Rails goes, I think a certain book and screencast series fit the bill.

RB: Our audience is made of mainly of enterprise developers.  Is Rails 3 ready for the enterprise and how do you see it stack up against current enterprise languages such as Java and C#?

MH: I have experience with neither Java nor C#, so I'm not in a position to compare them to Ruby, and I'm also unfamiliar with the Java and C# web frameworks. Based on its use in companies with high-traffic siteslike Twitter,, and Groupon, Rails certainly looks enterprise-ready.

RB: Enterprise applications often leverage many integration points with disparate system.   Do you see Ruby and in particular, Rails, have the ability to provide this type of support to enterprise developers?  Is Ruby/Rails better suited for integration than other languages and frameworks?

MH: I don't have much experience with enterprise applications, but I know that many companies, such as LinkedIn, use JRuby on Rails so that theycan interface natively with their many Java applications. Apparentlywhat you end up with is a WAR file, and you can deploy it like anyother Java web app.

RB: Is there anything specific about your background that prepared youto make the Ruby on Rails Tutorial?

MH: Web development is hard, much harder than most people realize, and my background in teaching physics helped me learn to anticipate which aspects of Rails would be confusing. During my five years teaching the core curriculum at Caltech, I constantly had to break down the subject (mainly mechanics and electrodynamics) into digestible pieces, always anticipating potential sources of difficulty. I applied that same approach when writing the Ruby on Rails Tutorial book.

RB: Are there any other projects you'd like to talk about?

MH: I sometimes half-jokingly refer to myself as "the world's leading anti-pi propagandist". Last year I wrote a paper called The Tau Manifesto, which proposes a new notation for an important mathematical constant: instead of pi = C/D, I use tau = C/r.I also started a holiday, Tau Day, on June 28, which competes with Pi Day on March 14. The project has gotten a lot of attention, including appearances in New Scientist magazine and

If you look at The Tau Manifesto, you'll see it's nicely formatted online and also comes as a PDF, much like the Rails Tutorial book.That's no coincidence: I produced both documents using a custom-written Ruby program called PolyTeXnic, which is built on top of the LaTeX typesetting system. I hope to release PolyTeXnic as an open-source project at some point to help other people make pretty technical documents for the web (while also producing attractive PDFs).

RB: Thank you for your time.

Readers who are interested in reading Michael's book online can visit the Ruby on Rails Tutorial book web site.  The book and videos are also available on the Ruby on Rails Tutorial web site.

Those planning on attending RailsConf 2011, May 16-19 in Baltimore, MD can hear Michael speak with his Intro to Rails - Part 1 & 2 tutorial.

About the Book Author


Michael Hartl is a programmer, educator, and entrepreneur. Michael was coauthor of RailsSpace, a best-selling Rails tutorial book published in 2007, and was cofounder and lead developer of Insoshi, a popular social networking platform in Ruby on Rails. Previously, he taught theoretical and computational physics at the California Institute of Technology (Caltech), where he received the Lifetime Achievement Award for Excellence in Teaching. Michael is a graduate of Harvard College, has a Ph.D. in Physics from Caltech, and is an alumnus of the Y Combinator entrepreneur program.

The publisher of this book, Addison-Wesley, has made the screencasts available on DVD format, which comes bundled with the book in a shrink-wrapped package.

Rate this Article

Adoption Stage

Hello stranger!

You need to Register an InfoQ account or or login to post comments. But there's so much more behind being registered.

Get the most out of the InfoQ experience.

Tell us what you think

Allowed html: a,b,br,blockquote,i,li,pre,u,ul,p

Email me replies to any of my messages in this thread

Twitter drops Ruby on Rails for Java by zqu dlyba

Twitter drops Ruby on Rails for Java

Impressive - Rails manages one billion queries per day! by Robert Sullivan

If you read the article, the Twitter front end service architecture, based on Ruby on Rails, was able to manage the load for one of the biggest search engines in the world, handling one billion queries. Yes, by converting their front end to an asynchronous model, starting from a clean slate (no "technical debt", and running on Java, their latencies for the 95th percentile went from 800ms to 250ms.

And I bet if they rewrote it again, and converted it to Erlang, they could improve performance even more.

Re: Twitter drops Ruby on Rails for Java by cijo kg

Read this. There is one good explanation for this misleading title


Allowed html: a,b,br,blockquote,i,li,pre,u,ul,p

Email me replies to any of my messages in this thread

Allowed html: a,b,br,blockquote,i,li,pre,u,ul,p

Email me replies to any of my messages in this thread

3 Discuss

Login to InfoQ to interact with what matters most to you.

Recover your password...


Follow your favorite topics and editors

Quick overview of most important highlights in the industry and on the site.


More signal, less noise

Build your own feed by choosing topics you want to read about and editors you want to hear from.


Stay up-to-date with curated articles from top InfoQ editors

"You dont know what you dont know" change that by browsing what our editors pick for you.