How to Generate a Sitemap?
MPG requires its sitemap to be generated since the generated pages aren't your typical WordPress entities. MPG entities are kept as 'virtual'. Though it has no negative SEO effect, since most frameworks and systems generate 'virtual' pages as well, it is an important differentiation for WordPress sites, as WordPress generates its sitemap from entities registered in its database.
✅ Prerequisite: Verify Your Page Count
Before generating a sitemap, confirm that your MPG project is showing a page count greater than zero.
- Go to your MPG project in the WordPress dashboard.
- Check the page count displayed in the project overview.
📝 Important: If the page count shows 0, the sitemap will fail. See Troubleshooting Zero Pages below before proceeding.
Steps to Generate a Sitemap
1. Go to your MPG project.
2. At the very top of the page, select the Sitemap tab.
3. Give your sitemap a name, preferably without spaces. Example: mpg-sitemap.
4. Unless you have a specific goal, leave the rest of the settings as they are and press the Save and generate button.
5. Copy the Current sitemap URL in the bottom right-hand corner of the table. Add the MPG sitemap as an additional sitemap in Google Search Console.
6. Manually check a couple of URLs through Google Search Console to confirm indexability. You can also watch the short tutorial video below for a step-by-step walkthrough:

📝 Note: If you open the XML sitemap, you may get a warning that the file doesn't contain "styles". That is OK, as this file is for search engines only.
🔧 Troubleshooting Zero Pages
If your project shows 0 pages, it usually means the data source connection has been lost or the source file has not been loaded correctly. Follow these steps to restore it:
1. Open your MPG project and go to the Source tab.
2. Check which source type you are using:
- Uploaded file (CSV/XLSX/ODS): Re-upload your file by clicking Browse and selecting the file again.
- Direct link (Google Sheets or remote CSV): Verify the link is still publicly accessible, then click Fetch and use to re-sync the data.
3. Once the data loads, click Save (or Save and generate on the Sitemap tab) to regenerate the project pages.
4. Return to the project overview and confirm the page count is now greater than zero before attempting to generate the sitemap again.
If you are using a Google Sheets link, make sure the sheet is set to Anyone with the link can view before fetching. Private sheets will return no data.
⚠️ Common Error: "To create sitemap, call addUrl or addUrls function first"
This error appears when the sitemap generator runs but finds no URLs to include — which happens when the project page count is zero.
How to fix it:
- Follow the Troubleshooting Zero Pages steps above to restore your data source.
- Once your page count is greater than zero, go to the Sitemap tab and click Save and generate again.
If the page count is correct but the error persists, check the WordPress base path settings under MPG → Advanced Settings and ensure the base path matches your site URL.
Troubleshooting Sitemap URLs
Sitemap URLs show an IP address instead of your domain name
If your MPG sitemap URLs show a server IP address (e.g., http://123.45.67.89/your-page/) instead of your domain, Google Search Console may report indexing errors. This is not an MPG bug — MPG reads the site URL from WordPress and does not rewrite it. The issue is typically caused by a misconfigured WordPress Site Address, a stale cache, or a reverse proxy on the server.
To fix it, work through these steps in order:
- Check your WordPress Site Address: Go to Settings > General and make sure both the WordPress Address (URL) and Site Address (URL) fields show your domain name, not an IP. Update if needed and click Save Changes.
⚠️ Important: Changing these URL fields can affect logins and redirects. Verify both values carefully before saving.
Regenerate the sitemap: In your MPG project, open the Sitemap tab and click Save and generate so MPG picks up the correct URL.
Clear all caches: Purge your caching plugin (WP Rocket, LiteSpeed Cache, etc.), any server-level cache (Nginx, Varnish), and your CDN cache (Cloudflare, BunnyCDN) to remove any stale sitemap copies.
Still seeing an IP? A reverse proxy or server rewrite rule may be replacing your domain. Contact your hosting provider and ask them to check their server configuration.
Once the issue is resolved, open the sitemap in a browser to confirm domain names appear, then re-submit it in Google Search Console > Sitemaps and monitor the Coverage report.
💡 Tip: To find your sitemap URL, go to the Sitemap tab in your MPG project and copy the Current sitemap link shown at the bottom of the table.
