I deploy ramrom.io by hand. There is no CI pipeline, no deploy button, no rollback. It is me, an SFTP client, and a shared hosting account. That is fine for a small site, but it means the order I upload files in is the whole deploy strategy. Get it wrong and visitors see a broken page for a few minutes. Get it right and nobody notices anything changed at all.
Here is the order I follow, and why each step sits where it does.
1. Assets first
CSS, JavaScript, images, icons — everything a page references — goes up before any page that uses it. The reason is simple: a page can only look broken if it points at a file that is not there yet. If I upload the page first and the new stylesheet a minute later, anyone who loads the page in that minute gets unstyled content. If I upload the stylesheet first, the old page simply ignores it, because the old page points at the old filename or the same filename with the old content cached. Either way, nothing breaks.
There is one trap here. If the new CSS file has the same name as the old one, overwriting it can change the look of the live page before the matching HTML goes up. That is usually harmless if the change is small, but if I have renamed a class in the CSS and the HTML still uses the old name, the page looks wrong until the HTML arrives. So I keep my changes small, and I upload assets and pages in the same session, minutes apart, never hours.
2. Pages second
Once the assets are in place, I upload the HTML pages. Now the new page arrives and finds everything it needs already sitting on the server. The page, its stylesheet, its script — all present at the moment the first visitor loads it.
I upload the least important pages first and the homepage last. If something goes wrong halfway through — a dropped connection, a file that refuses to transfer — the damage is limited to a guide page nobody is looking at right now, not the front door. The homepage is the page most people land on, so it gets updated when everything else is already proven.
3. Cache-bust last
This is the step people skip, and it is the step that causes the most confusion. Browsers and CDNs cache static files. If I change style.css but the page still says style.css, a returning visitor's browser will happily serve the old copy for hours or days. The fix is a version query string: style.css?v=3. The browser treats that as a different file and fetches the fresh one.
The version bump has to come last, because it is the switch that activates the new files. I update the ?v= number in the HTML only after the new CSS and JS are already on the server. If I bumped the version first and the asset upload failed, the page would point at a file that does not exist yet. Bump last, and the new version number only ever points at files that are already there.
The same logic applies to the service worker. My sw.js caches pages and assets, so a bad cache can trap visitors on old code. I version the worker too, and I bump it only after everything else is in place.
The checklist
So the deploy is three lines on a sticky note:
- Upload assets — CSS, JS, images, icons.
- Upload pages — least important first, homepage last.
- Bump the
?v=numbers — the switch that turns the new files on.
Then I check the live site the way a visitor arrives: open the homepage, click through to a tool page, run a real download. If it works, the deploy is done. If it does not, I know exactly which step to look at, because each step only touches one kind of file.
No pipeline, no staging server, no deploy tool. Just an order, followed every time. Boring, but it has never left a visitor staring at a broken page — and on a site people visit to get one job done, that is the whole point.