37 ms·
The WebGL update is awesome! The costs of hosting map tiles for the whole world can be large. How are you funding it?
by modeless 5y ago
The WebGL update is awesome! The costs of hosting map tiles for the whole world can be large. How are you funding it?
- tppiotrowski 5y agoGreat question. It costs nothing up to 50K map loads [1], but I did burn some money learning along the way: I went with Mapbox and Maptiler for tiles early on. Initially I used Leaflet with raster map tiles and raster elevation tiles. Mapbox free-tier for raster tiles was 750,000 tiles per month and I exceeded that a few months in. Next I used Leaflet with [maplibre/mapbox]-gl-leaflet plugin which allowed me to use unlimited vector map tiles from Mapbox up to 50K map loads. However, I continued to use raster elevation tiles and these soon started exceeding 750,000 tiles per month. Finally I switched to Mapbox GL JS. This allows you 50K map loads a month and unlimited loading of elevation and vector map tiles per map load. I used Maplibre GL JS for a bit, but it's missing the 3D terrain functionality so I went with Mapbox instead. In general, it would cost about $100 for every 3000 visitors before switching to Mapbox GL JS. [1] https://www.mapbox.com/pricing#maploads https://www.mapbox.com/pricing#maploads
- modeless 5y agoBeing on the HN front page is going to blow out your budget for the month probably. Hope it doesn't cost you too much! I had issues with my own site using Street View which is even more expensive than maps (https://james.darpinian.com/satellites/ https://james.darpinian.com/satellites/) until I found out you can apply for large amounts of free Google Maps API credits for educational and non-profit use. It's a little stressful because if you exceed your credits and don't deactivate the API in time you can still end up with a large bill, and the credits have to be re-approved every year in a slow and uncertain manual process. But hey, it's free and pretty generous, and nobody else has Street View so my site can't work without it.
- tppiotrowski 5y agoIt's a little early to say, but someone posted it on r/InternetIsBeautiful last month and it had about 75K visitors over two days. It looks like the front page of HN will be just a fraction (20%?) of that traffic. Reddit is truly massive, but I appreciate the HN discussions more.
- modeless 5y agoYou're right, I went and looked up my stats and HN doesn't seem as large as I thought. My biggest traffic days have been from Facebook. When Starlink is visible over a major city, I sometimes get a bump in traffic from people sharing the site. I was skeptical at first that adding social share buttons was important, but I think it actually has driven quite a bit of traffic. And I've gotten a ton of twitter followers which is cool. Though they don't actually care about what I tweet about, it's just nice to have a big number on my profile.