Absolute vs Relative Links : Technical Difference

后端 未结 2 1760
春和景丽
春和景丽 2021-01-27 12:36

Which is better option or there is no difference in terms of speed or other issues like SEO, Backlinks

href=\"http://www.example.com/contact\"

href=\"../../conta

2条回答
  •  清酒与你
    2021-01-27 13:34

    There is no (measurable) difference in speed or anything as regards to search engines and other software that processes HTML pages as delivered on the web.

    The reason is that relative URLs are resolved to absolute URLs applying well-defined algorithms that are known to authors of relevant software. So when your page contains href="../../contact", it will be resolved using the current base URL, and the nanoseconds required for this are ignorable.

    The use of relative vs. absolute URLs from the authoring point is a different issue, and well covered in the question already mentioned: Absolute vs relative URLs

提交回复
热议问题