Hello All,
I am new in SharePoint and I want to know the difference between `SP.Context.Site.Url, SP.Context.Web.Url and SP.Context.Site.RootWeb` ?
Please help me to know the difference between them.
Thanks in advance.
Know the answer? Post it. Somebody with the same question will find it here.
Answer a question in the forums and earn +20 SHARP for every answer.
See unanswered questions
DevSocialUpcoming · 3rd editionAI Agents ConferenceDec 1–3, 2026Live onlineFree to attend5days leftRegister
Ranjeet PatraRank #1,436 · 1.1K reputationPosted Apr 18, 2017, 3:25 AM EDT
Yogendra BhardwajRank #2,141 · 666 reputationPosted Apr 21, 2017, 4:24 PM EDT
The SP.Context.Web class represents an instance of a single website. It is often confusing to developers because the root web of a site collection (which is created when a site collection is created) is an instance of the SP.Context.Web class.