Xml sitemap subdirectory & root directory problem

Questions about sitemaps. https://ghost.org/blog/xml-sitemaps/

We have a ghost blog running on a subdirectory https://www.goeasysmile.com/blog. But also have a sitemap on our static website at root directory.

Where is the ghost site map automatically generated?
Is there a way to merge the two and update my root sitemap?
How best to handle this situation?

Howdy! Looks like your sitemap for the blog is here https://www.goeasysmile.com/blog/sitemap.xml

I went and looked at your main site to see if there’s a sitemap and it appears to have already got your blog pages in there :+1: https://www.goeasysmile.com/sitemap.xml

So you don’t need to do anything :smile:. It could be automated though, does your main site use a CMS or is it a set of static pages?

Thanks for reaching out! https://www.goeasysmile.com/sitemap.xml is a static site showing and those blog posts are not from the ghost blog.

How do I automate this? so https://www.goeasysmile.com/sitemap.xml has the updated ghost sitemaps from when my Authors add articles?

You could use the robots.txt sitemap declarations:

Hey that’s a great idea! @alemac852 using this method you could just point search engine bots to the blog sitemap generated with Ghost and then Ghost would do the rest :rocket:

33%20PM

Also is it ok to have these links as broken?

I think those are all links in the demo blog posts from Ghost, you can delete those posts entirely if you want :slight_smile:

Hey,

I am facing a similar situation right now and was wondering what the ideal implementation would be. I am in the process of generating the sitemap for my NextJS app and I run the ghost app on /blog as well.

Should I use add both the sitemap URLs in my Google console or is there a better/different way I should be doing this?

Hi there. I did a little bit of searching and the xml sitemap spec allows for the linking of multiple sitemaps, if your main site and /blog is generating their own sitemaps then you can link the /blog sitemap in the main sitemap. Google developer docs has some more information on how to do this:
https://support.google.com/webmasters/answer/75712?hl=en