Adding a CDN does not usually mean replacing your hosting — it means placing a CDN in front of the hosting you already have, so that it handles serving your content while your original server becomes the backup source it occasionally checks in with.
Setting one up commonly follows one of two patterns: DNS-level (the most common for a standalone CDN service — you change your domain's nameservers, per the connecting-a-domain lesson, to the CDN provider's, and it sits transparently between every visitor and your actual server), or built-in (many cloud and static hosting platforms, covered earlier, include a CDN automatically by default, with nothing separate to configure at all).
A CDN stores a copy of your content and serves that copy for a period of time before checking your original server again — this is caching, and it is exactly why a CDN is fast: most requests never have to travel back to the original server at all. The trade-off is that a change to your site does not appear everywhere instantly — cached copies at each edge location need to expire or be manually cleared, a step usually called a purge or cache invalidation, offered as a button or an API call in most CDN dashboards.
After updating a site sitting behind a CDN and not seeing the change, check for a stale cached copy before assuming the deployment itself failed — a manual purge, where the platform offers one, resolves this immediately, and is a genuinely common step to forget.
This is where the "cheap hosting plus a free CDN" combination genuinely earns its place: most of your traffic's bandwidth and server load moves to the CDN's edge network, which frequently means a modest, inexpensive hosting plan can comfortably serve a much larger audience than it could unassisted — often outperforming a considerably more expensive hosting plan running with no CDN at all.
A CDN speeds up delivering content, but it cannot speed up a slow database query or inefficient server-side logic — those still run entirely on your original server, on every single request that reaches it, exactly as before. A CDN complements good backend performance; it does not replace the need for it.