Who will find this article useful?
Posted: Wed Jan 08, 2025 3:23 am
If you are an experienced SEO specialist, many things will be obvious to you, but for junior or beginner specialists this will cause an insurmountable quest. So, this article is for you (intern, junior specialists)
Parsing links from a sitemap
How long will it take you to extract all the links from a sitemap (sitemap.xml) if there are more than 10,000 of them? The answer is 10 seconds.
Service:
Extract links from a sitemap - this tool is quite easy to use, take the sitemap link el salvador telegram and paste it into the service field! Get the finished result, (tested on large sitemaps with more than 40,000 URL addresses).
Next, you can run these links through redirect checkers and check if there are any broken links in the site map. Convenient, practical, fast!
Redirect checker in Google Sheets
You have downloaded all the links from the sitemap and you need to find out their response code. Here, I can recommend you to create this tool directly in Google Sheets. I will tell you step by step what you need to do:
Step 1. Setup
First, we need to create a new table in Google Sheets and name it as you like.
In the table that opens, select Extensions => Apps Script
The script editor will open in front of you.
This field will be filled with a standard function, you will need to delete everything that is there and add this script:
function getStatusCode (url) {
var url_trimmed = url.trim();
// Check if script cache has a cached status code for the given url
var cache = CacheService.getScriptCache();
var result = cache.get(url_trimmed);
// If value is not in cache/or cache is expired fetch a new request to the url
if (!result) {
var options = {
'muteHttpExceptions': true,
'followRedirects': false
};
var response = UrlFetchApp.fetch(url_trimmed, options);
var responseCode = response.getResponseCode();
Parsing links from a sitemap
How long will it take you to extract all the links from a sitemap (sitemap.xml) if there are more than 10,000 of them? The answer is 10 seconds.
Service:
Extract links from a sitemap - this tool is quite easy to use, take the sitemap link el salvador telegram and paste it into the service field! Get the finished result, (tested on large sitemaps with more than 40,000 URL addresses).
Next, you can run these links through redirect checkers and check if there are any broken links in the site map. Convenient, practical, fast!
Redirect checker in Google Sheets
You have downloaded all the links from the sitemap and you need to find out their response code. Here, I can recommend you to create this tool directly in Google Sheets. I will tell you step by step what you need to do:
Step 1. Setup
First, we need to create a new table in Google Sheets and name it as you like.
In the table that opens, select Extensions => Apps Script
The script editor will open in front of you.
This field will be filled with a standard function, you will need to delete everything that is there and add this script:
function getStatusCode (url) {
var url_trimmed = url.trim();
// Check if script cache has a cached status code for the given url
var cache = CacheService.getScriptCache();
var result = cache.get(url_trimmed);
// If value is not in cache/or cache is expired fetch a new request to the url
if (!result) {
var options = {
'muteHttpExceptions': true,
'followRedirects': false
};
var response = UrlFetchApp.fetch(url_trimmed, options);
var responseCode = response.getResponseCode();