The Bootstrap CDN (Content Delivery Network) is the way of including required Bootstrap libraries from third-party servers.
If you do not want to host libraries on your own due to bandwidth, speed or any other issues then you may use CDN links hosted by third parties.
The CDN from the popular sources can also be useful for the speed of your website. For example, some other website also used a CDN link of Bootstrap 4 from the same source and a user visited that website. Your web page also used that CDN link then it will be loaded from the user’s cache and thus helps in increasing the load time.
The maxcdn CDN for Bootstrap
The maxcdn is one the most popular host for CDN links not only for Bootstrap but other libraries as well.
The Bootstrap 4 CSS CDN link (minified version):
The markup with this link that you may use in the <head> section or another part:
<link href="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0/css/bootstrap.min.css" rel="stylesheet" integrity="sha384-Gn5384xqQ1aoWXA+058RXPxPg6fy4IWvTNh0E263XmFcJlSAwiGgFAW/dAiS6JXm" crossorigin="anonymous">
The development version is also available:
This is useful if you want to look at the CSS classes or require to override certain properties in your external CSS files.
The minified version:
The code for including in the web page:
In Bootstrap 4, the popper.js is also required for various components like popovers, tooltips etc. You may include bundled JS for that or include popper.js or its minified version separately.
The bundled JS CDN link from maxcdn:
See the CDN links below for Bootstrap version 3:
For CSS, use this HTML code:
<link rel=”stylesheet” href=”https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css”>
The Bootstrap JS CDN:
The jQuery CDN from maxcdn
For different components of Bootstrap (dropdown, popovers, tooltips, carousel etc.) that require JS, the jQuery library is also required. The jQuery library CDN link from maxcdn:
The CDNJS also hosts a big collection of libraries including Bootstrap. You may find any CDN link from the 3000+ hosted libraries here.
Following is the list of Bootstrap CDN links.
The developer’s version of Bootstrap 4 CSS:
The minified version of HTML:
<link rel=”stylesheet” href=”https://cdnjs.cloudflare.com/ajax/libs/twitter-bootstrap/4.0.0/css/bootstrap.min.css” crossorigin=”anonymous”>
The minified version with the <script> tag to be included in a web page:
Following are the Bootstrap v3.3.7 links.
CSS developer version:
CSS minified version with HTML code:
<link rel=”stylesheet” href=”https://cdnjs.cloudflare.com/ajax/libs/twitter-bootstrap/3.3.7/css/bootstrap.min.css” crossorigin=”anonymous”>
Minified version of 3.3.7