getStatusCode

Overview

Get the Status Code of an URL

This function only return the status code of a request.

For following redirections and get the final status code please combien this function with the premium one called checkRedirectChain.

Video Example

Arguments

  • url: The URL to get the status

Expected Output

  • number: The Status Code of the requested page

Text example

getStatusCode("https://github.com/NachoSEO")
// 200

getStatusCode("http://github.com/NachoSEO")
// 301

getStatusCode("https://github.com/invented-path")
// 404

Use cases

  • SEO checks of your site in Google sheets

  • Control web migrations directly in Sheets

Last updated