Creating and editing the tree might be free, but Ancestry.com's whole appeal lies in the huge range of data they house, much of it gleaned from public records. I'm not against them charging some for the service of having scanned and indexed that data, and for operating the servers to host it, but in my opinion they're overcharging for that service based on our public data by a fair margin.
Some of the data itself is from the public record, but compiling all of it yourself would be prohibitively expensive. It would take many trips to various libraries, churches, courthouses, etc. in lots of far-flung places in different cities, states, and countries. And that's all before you start indexing, searching, copying, or scanning any records.
Then consider they're hosting all those billions of records, have developed decent software for both building family trees and documenting them with their database of sources, and continually improve their software and increase their database holdings. The only reason they can charge so little is the economy of scale based on their huge userbase.