` Use jQuery In Website Using CDN

Use jQuery In Website Using CDN

If you don’t want to download and host jQuery yourself, you can include it from a CDN (Content Delivery Network).

Using jQuery Official CDN

To use jQuery from official CDN, use one of the following:

uncompressed
<script src="https://code.jquery.com/jquery-3.2.1.js"></script>
minified
<script src="https://code.jquery.com/jquery-3.2.1.min.js"></script>
slim
<script src="https://code.jquery.com/jquery-3.2.1.slim.js"></script>
slim minified
<script src="https://code.jquery.com/jquery-3.2.1.slim.min.js"></script>

Using Cloudfare CDN

To use jQuery from Cloudfare CDN, use one of the following:

uncompressed
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.2.1/jquery.js"></script>
minified
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.2.1/jquery.min.js"></script>
slim
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.2.1/jquery.slim.js"></script>
slim minified
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.2.1/jquery.slim.min.js"></script>

Also Read