API key required

You have probably landed here because you saw that written across your map. Nothing is broken and nothing has been blocked — your tiles are still loading. Here is what changed, and how to clear it in about a minute.

What is happening

Your application is requesting CARTO basemap tiles without an API key, so we are serving those tiles with a notice written across them. The map still works — this is a message, not a block.

If you inherited this code, or copied a tile URL from a tutorial years ago, this will be the first you have heard of any of it. That is genuinely common, and it is the reason we are putting the message on the map rather than simply turning anything off.

How to clear it

Request a key. Tell us your email, the domain you will use the basemaps on, and roughly what you are building. We email the key straight back — there is no approval queue and you do not need a CARTO account.

Request an API key

Then add it to your tile URL as a key parameter:

https://basemaps.cartocdn.com/rastertiles/voyager/{z}/{x}/{y}.png?key=YOUR_KEY

In Leaflet that looks like:

L.tileLayer('https://{s}.basemaps.cartocdn.com/rastertiles/voyager/{z}/{x}/{y}.png?key=YOUR_KEY', {
  attribution: '&copy; <a href="https://www.openstreetmap.org/copyright">OpenStreetMap</a>, &copy; <a href="https://carto.com/attributions">CARTO</a>',
  subdomains: 'abcd', maxZoom: 20
}).addTo(map);

If the watermark is still there afterwards, force-refresh — your browser and our CDN both cache map tiles, so an old one can linger for a moment.

Using basemaps inside the CARTO platform? Builder, Workflows, and applications authenticated with your CARTO credentials are unaffected. There is nothing for you to do.

Why we are asking for a key

CARTO has given these basemaps away for many years, and we want to carry on doing that. The difficulty is that without a key we cannot tell who is using the service, or how much.

That means we cannot warn anyone before they hit a limit, we cannot tell a student project apart from a company running a product on our tiles, and we cannot plan capacity honestly. A key fixes all three — and it is the reason we can set the free allowance as high as we have, which would not have been responsible while usage was anonymous.

Keys are free up to a fair use limit of 5 million tile requests per calendar month. Two things we ask in return: keep the CARTO and OpenStreetMap attribution visible, and do not share your key across unrelated projects.

If you go past the limit we will get in touch rather than cut you off. Non-commercial projects usually just get a higher limit. For commercial use we may ask you to move onto a commercial agreement — talk to us and we will find something that fits.

While you are here: consider vector

The watermark applies to our raster (PNG) basemaps, which are the older of our two services and are being retired. The vector basemaps are better on every axis that matters:

  • Sharper cartography — crisp at any zoom and on any display density, with no separate @2x request.
  • Fresher data. We are considering stopping data updates to the raster basemaps, in which case that cartography stays where it is while vector keeps moving.
  • Restyleable in the browser — change colours, labels and layer visibility at runtime instead of baking them into a PNG.
  • Faster and cheaper to serve, which is a large part of how we can afford to keep the free allowance generous.

Only raster is watermarked today. Even so, we would suggest getting a key whichever you use — we may extend the requirement to vector later, and having one already means you would never notice.

The basemaps FAQ has a per-style migration table from raster to vector.

The details

Full terms are in the CARTO Basemaps Terms and Conditions — the parts most people need are the API key requirement, the fair use limit, and the attribution requirement.