Keep old URLs
When a kit site replaces a client's existing site, every page that people link to and search engines list should stay at its URL. Hostsmith doesn't redirect old URLs to new ones yet, so the new site keeps the old paths exactly.
List the old site's paths
.hostsmith/old-urls.txt holds the old site's paths, one per line. Lines that start with # are comments.
# Paths of the old site that this site keeps
/
/services
/services/painting
/about
/blog
/blog/what-a-fixed-quote-should-include
List every page of the old site: its sitemap, if it has one, is a good start. The file in a new site lists the example's pages: replace it.
Keep the paths
- Pages are served at their file's path, so
pages/services/painting.en.mdis/services/painting. Name the files after the old paths. - Collections are served under their base path, such as
/blog. A site moving from Webflow keeps Webflow's base path for its posts, such as/post, with the base path insrc/site.config.ts:collections: { news: { basePath: "/post" }, }, - More languages keep the default locale at the root. Other locales are under their path, such as
/de, as Webflow does.
Check them
After a build:
npm run check:urls
It checks that each path has a page in dist/, in the files Hostsmith serves for it: /about from about, about/index.html or about.html, and /about/ from about/index.html. It names every path without a page, and fails.
Before the client's domain moves, check the production site too, at its Hostsmith address:
npm run check:urls -- --live https://acme.us.hostsmith.link
Run it again on the client's domain once it points to Hostsmith. The README describes the exact lookup.
