Does anyone have experience with running Web maps (tile server + client JS scripting) on Amazon Web Services (S3, EC2 etc...)?

What kind of AWS configuration is needed for running a low-to-medium bandwidth Web map app, covering a small(-ish) area (city to small-country size)?

All of the tiles would be pre-rendered and uploaded to S3. Ideally I would need a tile serving app on the web server that could serve MBTiles (instead of uploading hundreds of thousands of tile bitmaps individually).

Some kind of EC2 instance would be needed, but what kind?

What I'm basically looking for is some feedback about how viable AWS is for hosting your own web maps as an individual (which means it shouldn't cost too much, say up to $30/month). I've been hosting my web maps for some time through "ordinary" hosting providers, but these have their own limitations (upload bandwidth is one, speed is another).

I'm also looking for any good alternatives to AWS and anything to watch out for when using cloud services for web maps.


6 Answers 6


When picking an architecture for a service that relies so much on a 'classic' architecture like web maps never underestimate the effectiveness of more traditional hosting solutions like RackSpace Cloud Servers or Linode.

You will have much less choices to make (like use S3 or not, load balancers or not, backups, etc or not and how much is that going to cost?) whose outcome is difficult to predict AND, more importantly you will be able to use tools that you are already familiar with.

Having gone through the same myself some time ago I can tell you that the critical factors in my decision to host a web maps service on Rackspace rather than AWS were:

  1. Cloud Server are (more) resilient than EC2 instances. EC2 instances are actually expected to fail and they will fail
  2. EBS volumes fail too (there's plenty of sad stories in the news) and generally have poor I/O
  3. unless you pick the larger instances I/O contention could be an issue (especially if you plan on seeding the tiles on EC2, rather than copying them over). It could also be an issue with MTBtiles databases
  4. Whenever you reboot your server the public ip will change: this does not happen on Linode or Rackspace
  5. You will have to come up with a backup and restore strategy yourself whereas both Linode and Rackspace provide point and click daily and weekly automated snapshots and restores
  6. If the host running your VPS fails Rackspace will take care of relocating your instance and restarting it on a different server and they will do this in 4h (it's in their SLA). It happened to me while I was on holiday: it felt very professional. Linode should do the same
  7. Linode has a great availability SLA: 99.9% and they claim great performance because they don't overprovision
  8. Rackspace has recently come up with a volume strategy like EBS so disk space should not be an issue anymore. Previously if you needed lots of disk space you HAD to get a large instance while on EC2 you can provision storage, cpu and memory with finer control

With this I'm not saying that Amazon AWS is inferior to others, I'm just saying that sometimes traditional hosting solutions can scale as well as Cloud-based ones. A notable example is the StackExchange network itself.

So, in your case I would start up a large instance on Rackspace and then load all the data in a local Postgis instance. Then, after configuring the rendering engine I would seed the cache. A large instance will complete the seeding process fast enough so that it doesn't become too expensive to run. You can store tiles in the fs, MTBtiles, even on S3 (btw, you can serve S3 data on a CDN with CloudFront).

After the seeding completed I would reboot the server and resize it into a small (maybe even 512MB) instance as at that point it would only have to serve static data.

This is getting a kinda long answer so I'm going to stop here. If you want me to elaborate on certain aspects just drop a comment.

Disclaimer: I am not affiliated with Rackspace, Linode, or any other provider I cited.


I've been using WebFaction for hosting GIS data in a Postgresql/PostGIS database with MapServer and I think the service is unrivaled for the cost of <$10 per month. If you want to use PostGIS 2.0 you need to install it yourself which is a bit tricky, but they provide PostGIS 1.5 by default (you need to open a support ticket). This is a shared hosting service on CentOS where you have full flexibility to install anything in your own portion of the server.

I have not been using Webfaction for serving tiles, but they do provide 100GB of space; I'm not sure if the RAM would be too costly as the default is 256 MB (and each 256 block costs an additional $7 per month)


One other possibility that uses AWS:

You may want to look into using the AWS Lambda Tiler method that Seth Fitzsimmons devised. He has been using it for the Open Aerial Map project and I used it for a private client project while working at Stamen Design.

There is a thorough blog post which I wrote that documents how to set up the AWS Lambda Tiler on Medium.com. Note that the blog post only covers tiling raster data, but we also used this process at Stamen to drive our global Terrain Classic map tiles which are generated from a combination of OSM and Natural Earth data via PostgreSQL, PostGIS, Mapnik, and CartoCSS.

One of the benefits of this approach is that you don't have a tile server to maintain and you only pay per use of each AWS Lambda function call, which I'm fairly certain is on the cheap side for smaller projects that don't receive a huge amount of web traffic. One of the downsides of this approach is that the tiles are seeded by the user panning and zooming the map, so the first rendering can be on the slow side, though you could pre-seed the tiles ahead of time. Tiles are written and stored to S3 after they are first rendered, so subsequent tile loading is much faster.


To get detailed pricing for AWS services you can use the online calculator located here: http://calculator.s3.amazonaws.com/calc5.html

For a small EC2 instance running Linux, if you are willing to commit to a year, you can buy a Reserved Instance that will cost about $25/month. That is in comparison to about 44/month for on demand pricing, or no-contract pricing.

I think the short answer to your question is that if you are looking for an infrastructure provider to take care of your personal web mapping application needs, AWS might be overkill. If you are looking for IT provider for production apps, especially if they require HA and scalability, then AWS is your answer. This becomes even more true if you are creating apps that leverage the many glue services that AWS provides, such as SQS, SNS, SWF etc.

As to what kind of EC2 you need? That is a function your apps specific requirement. The whole point of cloud-based IT is that you can try before you buy. Test your app without commitment, and only when you know, make an informed decision about committing to an EC2 type over a period of time (the RI buy).


I am not an expert with much or really any knowledge about it other than I have been running a web server on amazon EC2 for some time now, So this is not an answer.

I am not sure you are utilizing these tools to their best use by pre-rendering and uploading.

  • The biggest part of my aws expense is on my data transfer (what you are talking about loading).
  • What else does your server have to do (unless you are utilizing licenses to render tiles and don't have license for the AWS).

If that doesn't deter or cause a re-think, Probably first pick your favorite map server, Then pick a supported OS for that map server, Then go to AWS EC2 and find the Instance that best meets your needs (size, memory, space, region).
There may or may not be an AMI containing all the stack you need so next get it configured and then install your stack.
There is a strong possiblility that you will accomplish all of that for "free" or cheap.


That true you can go for AWS if you are using the different services of them as AWS is quite costly. If you want to go for the cheaper prices with the same benefits i would recommend for https://fxdata.cloud or https://digitalocean.com as both of them are having appreciable services and cheapest prices. You will basically get all the OS and DBMS options with high reliability.

Not the answer you're looking for? Browse other questions tagged or ask your own question.