Skip to main content
added 88 characters in body
Source Link

Should I use absolute paths for CSS or JS resources in <link and <script tags?

Is there any reason?

Some SEO optimization say fix it, should I do it for any reason?

I do not know why, if everything is working fine?

<link rel="stylesheet" href="/css/main_rtl.css?v=5e6e47e9"> <script src="/lib/js/frameworks.min.js?v=5e6e47e9"></script> 

Vs

<link rel="stylesheet" href="https://sample.com/css/main_rtl.css?v=5e6e47e9"> <script src="https://example.com/lib/js/frameworks.min.js?v=5e6e47e9"></script> 

Is there any SEO-related point?

Shorter version is smaller HTML at least.

  • each page has canonical
  • domain only serve https version(http redirect to https)

Should I use absolute paths for CSS or JS resources in <link and <script tags?

Is there any reason?

Some SEO optimization say fix it, should I do it for any reason?

I do not know why, if everything is working fine?

<link rel="stylesheet" href="/css/main_rtl.css?v=5e6e47e9"> <script src="/lib/js/frameworks.min.js?v=5e6e47e9"></script> 

Vs

<link rel="stylesheet" href="https://sample.com/css/main_rtl.css?v=5e6e47e9"> <script src="https://example.com/lib/js/frameworks.min.js?v=5e6e47e9"></script> 

Is there any SEO-related point?

Shorter version is smaller HTML at least.

Should I use absolute paths for CSS or JS resources in <link and <script tags?

Is there any reason?

Some SEO optimization say fix it, should I do it for any reason?

I do not know why, if everything is working fine?

<link rel="stylesheet" href="/css/main_rtl.css?v=5e6e47e9"> <script src="/lib/js/frameworks.min.js?v=5e6e47e9"></script> 

Vs

<link rel="stylesheet" href="https://sample.com/css/main_rtl.css?v=5e6e47e9"> <script src="https://example.com/lib/js/frameworks.min.js?v=5e6e47e9"></script> 

Is there any SEO-related point?

Shorter version is smaller HTML at least.

  • each page has canonical
  • domain only serve https version(http redirect to https)
edited title
Link

Is there any point to use absolute URLs for asset files like css/js for SEO optimization?

formatting
Source Link
Patrick Mevzek
  • 8.6k
  • 1
  • 22
  • 42

Is there any point to use absoulte urlabsolute URLs for asset files like css/js?

Should iI use absolute pathpaths for cssCSS or js link forJS resources in <link and <script tags?

Is there any reason. Some?

Some SEO optimization say fix it, should iI do it for any reason?

I dontdo not know why?, if everything work file.is working fine?

<link rel="stylesheet" href="/css/main_rtl.css?v=5e6e47e9"> <script src="/lib/js/frameworks.min.js?v=5e6e47e9"></script> 

Vs

<link rel="stylesheet" href="https://sample.com/css/main_rtl.css?v=5e6e47e9"> <script src="https://sampleexample.com/lib/js/frameworks.min.js?v=5e6e47e9"></script> 

Is there any seoSEO-related point.?

Shorter version is smaller htmlHTML at least.

Is there any point to use absoulte url for asset files like css/js

Should i use absolute path for css or js link for <link and <script tags?

Is there any reason. Some SEO optimization say fix it, should i for any reason?

I dont know why? if everything work file.

<link rel="stylesheet" href="/css/main_rtl.css?v=5e6e47e9"> <script src="/lib/js/frameworks.min.js?v=5e6e47e9"></script> 

Vs

<link rel="stylesheet" href="https://sample.com/css/main_rtl.css?v=5e6e47e9"> <script src="https://sample.com/lib/js/frameworks.min.js?v=5e6e47e9"></script> 

Is any seo point.

Shorter version is smaller html at least.

Is there any point to use absolute URLs for asset files like css/js?

Should I use absolute paths for CSS or JS resources in <link and <script tags?

Is there any reason?

Some SEO optimization say fix it, should I do it for any reason?

I do not know why, if everything is working fine?

<link rel="stylesheet" href="/css/main_rtl.css?v=5e6e47e9"> <script src="/lib/js/frameworks.min.js?v=5e6e47e9"></script> 

Vs

<link rel="stylesheet" href="https://sample.com/css/main_rtl.css?v=5e6e47e9"> <script src="https://example.com/lib/js/frameworks.min.js?v=5e6e47e9"></script> 

Is there any SEO-related point?

Shorter version is smaller HTML at least.

Source Link
Loading