How do I get the referrer URL in an ASP.NET MVC action?

You can use Request.UrlReferrer to get the referring URL as well if you don’t like accessing the Request.ServerVariables dictionary directly.

Leave a Comment