Search code examples
javascriptjqueryjsapi

Is it essential to use a developer key in Google Jsapi calls?


I've been using Google Jsapi like so:

<script type="text/javascript" src="http://www.google.com/jsapi"></script>
<script type="text/javascript">
    google.load("jquery", "1.3");
</script>

But the Google docs recommend doing this:

<script type="text/javascript" src="http://www.google.com/jsapi?key=YOUR_KEY_HERE"></script>
    <script type="text/javascript">
        google.load("jquery", "1.3");
    </script>

In my experience, it seems to work whether you include the key or not.

Will I encounter any problems if I don't use a key?


Solution

  • I would say that if the documentation says you need to include it, then you should include it. They may start enforcing that rule with no further notice, and your application may stop working.

    If you restrict yourself to following the public API, you should be safe from Google changing their service, and your application breaking.

    That advice holds for any other non-public APIs as well.